Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
StefanBackstrand
Partner - Specialist
Partner - Specialist

Power Tools for QlikView

Dear Community members!

On Monday, November 7th, the Power Tools for QlikView is released to the general public!

This is the main thread to discuss the Power Tools, share ideas and report bugs. It will work as an interim solution until we get the Power Tools section up and running.

We will update this thread with all necessary information as soon as the package is released, so stay tuned!

Best regards,


The Power (Tools) team

30 Replies
StefanBackstrand
Partner - Specialist
Partner - Specialist
Author

bnichol: Thank you for your suggestions! I have put them on our list of proposed features.

dvasseur
Partner - Creator III
Partner - Creator III

Some feedback for the Shared File Viewer and Server Object Handler tool:

  • Use .NET framework 3.5 instead of 4.0 please (winXP and Win2003 users)
  • I do agree with bnichol, having some key fields (name, title...) would be great, and even better, the ability to define which field would be displayed on a specific column
  • Ability to filter objects per Owner (filter on other fields may be useful too)

A strange thing I've discovered with these tools: it seems that deleted objects (clone an existing object and then delete it) are not really deleted in the .Shared file, at least they are still displayed in Server Object Handler. I don't know if it's a bug or not but if not a status column with 'ACTIVE' or 'DELETED' would be useful

Not applicable

I do not think it is possible to use .NET 3.5 instead of 4.0 given that the latest version of QV server uses the 4.0 and that some QV dll are referenced by the power tools.

cva1962
Contributor
Contributor

Hi...this is something GREAT!.

Actually requested exactly the possibillity to export "current license users".

Just a little problem for me...when I try to put the export example in a QV application...the command window doesn't automatically close.

When I manually close command window, the file is exported and is just perfect.

What do I need to do?

Current script in application is:

EXECUTE cmd /c "D:\QlikView Storage\Private Data\Cmd Files\Power Tools\qv-user-manager.exe" --list cal > cals.csv;

 

Br

Christer

Anonymous
Not applicable

Is it possible to use a "join" in a query with the XMLDBViewer tool?

If not, it would be great to be able to query tables much like in SQL.

Nothing too fancy, just the basic SELECT..FROM..JOIN...WHERE,

INSERT, DELETE, UPDATE, etc...

StefanBackstrand
Partner - Specialist
Partner - Specialist
Author

Jeffrey,

No, we don’t support JOIN operations or any table manupulation via queries today. You can of course edit tables manually in the table view. I will however bring it to the next discussion about this tool.

Just remember, that modifying a QVPR database during runtime under QMS is not a supported scenario.

/s

Stefan Bäckstrand

Senior Technical Expert, PM

Email: Support@qlik.com<mailto:Support@qlik.com>

qlik.com<http://www.qlik.com/>

The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from any computer.

Not applicable

Hello,

is it possible to use PowerTools in command line to launch an EDX programmed task ? If possible, how could we retrieve return codes ?

Regards

Regis

Not applicable

Hello,

I''ve tried Powertools QMSCLIENT tool and works fine (if command line version exists it will be great)

I need to launch an EDX task with QV11 so I've made a script with Visual C# .Net 2010.

It does'nt work neither with .Net 3.5 or 4.0 console application version

Everything's ok to call service key and have a look in QVS service launch and method related

But I can't work with Distribution Service and I don't know why (it works with powertool QMSAPI but not with my script). Is there something's special with Distribution Service ?

Here are my scripts:

program.cs

using System;

using System.Linq;

using System.Threading;

using System.Collections.Generic;

using System.ServiceModel;

using System.ServiceModel.Channels;

using System.ServiceModel.Configuration;

using System.ServiceModel.Description;

using System.ServiceModel.Dispatcher;

using MyTestApplication.QMSAPI;

namespace MyTestApplication

{

    class ServiceKeyBehaviorExtensionElement : BehaviorExtensionElement

    {

        public override Type BehaviorType

        {

            get { return typeof(ServiceKeyEndpointBehavior); }

        }

        protected override object CreateBehavior()

        {

            return new ServiceKeyEndpointBehavior();

        }

    }

    class ServiceKeyEndpointBehavior : IEndpointBehavior

    {

        public void Validate(ServiceEndpoint endpoint) { }

        public void AddBindingParameters(ServiceEndpoint endpoint, BindingParameterCollection bindingParameters) { }

        public void ApplyDispatchBehavior(ServiceEndpoint endpoint, EndpointDispatcher endpointDispatcher) { }

        public void ApplyClientBehavior(ServiceEndpoint endpoint, ClientRuntime clientRuntime)

        {

            clientRuntime.MessageInspectors.Add(new ServiceKeyClientMessageInspector());

        }

    }

    class ServiceKeyClientMessageInspector : IClientMessageInspector

    {

        private const string SERVICE_KEY_HTTP_HEADER = "X-Service-Key";

        public static string ServiceKey { get; set; }

        public object BeforeSendRequest(ref Message request, IClientChannel channel)

        {

            object httpRequestMessageObject;

            if (request.Properties.TryGetValue(HttpRequestMessageProperty.Name, out httpRequestMessageObject))

            {

                HttpRequestMessageProperty httpRequestMessage = httpRequestMessageObject as HttpRequestMessageProperty;

                if (httpRequestMessage != null)

                {

                    httpRequestMessage.Headers[SERVICE_KEY_HTTP_HEADER] = (ServiceKey ?? string.Empty);

                }

                else

                {

                    httpRequestMessage = new HttpRequestMessageProperty();

                    httpRequestMessage.Headers.Add(SERVICE_KEY_HTTP_HEADER, (ServiceKey ?? string.Empty));

                    request.Properties[HttpRequestMessageProperty.Name] = httpRequestMessage;

                }

            }

            else

            {

                HttpRequestMessageProperty httpRequestMessage = new HttpRequestMessageProperty();

                httpRequestMessage.Headers.Add(SERVICE_KEY_HTTP_HEADER, (ServiceKey ?? string.Empty));

                request.Properties.Add(HttpRequestMessageProperty.Name, httpRequestMessage);

            }

            return null;

        }

        public void AfterReceiveReply(ref Message reply, object correlationState) { }

    }

    class Program

    {

        static void Main(string[] args)

        {

            try

            {

                // create a QMS API client

                IQMS apiClient = new QMSClient();

                // retrieve a time limited service key

                //apiClient.ClientCredentials.Windows.AllowNtlm = true;

                //var ws = new QMSAPI.IQMS.Handler("BasicHttpBinding_IQMS");

                //ws.ClientCredentials.UserName.UserName = "administrator";

                //ws.ClientCredentials.UserName.Password = "@dm!nQLIK";

                //var result = ws.executeMyMethod();             

                ServiceKeyClientMessageInspector.ServiceKey = apiClient.GetTimeLimitedServiceKey();

                // get a list of QVS services

                //Console.WriteLine(apiClient.GetAlertText());

                ServiceInfo qdsService = apiClient.GetServices(ServiceTypes.QlikViewDistributionService).FirstOrDefault();

              

                if (qdsService != null)

                {

                    Console.WriteLine("in1");

                    TriggerEDXTaskResult result = apiClient.TriggerEDXTask(qdsService.ID, args[0], args[1], "", null);

                    Console.WriteLine("in2");

                    EDXStatus executionStatus = null;

                    //Wait until the task is completed or 60 seconds has passed.

                    //SpinWait.SpinUntil(() =>

                    //{

                    System.Threading.Thread.Sleep(1000);

                    Console.WriteLine("Checking the task...");

                    //Get the current state of the task.

                    executionStatus = apiClient.GetEDXTaskStatus(qdsService.ID, result.ExecId);

                    //Return true if the task has completed.

                    //executionStatus != null && executionStatus.TaskStatus == TaskStatusValue.Completed;

                    //}, 60 * 1000);

                    //Write the result

                    if (executionStatus != null)

                        Console.WriteLine(executionStatus.TaskStatus);

                    else

                        Console.WriteLine("Failed to get execution status.");

                } //else

                Console.WriteLine("test");

            }

            catch (System.Exception ex)

            {

                Console.WriteLine("exception:"+ex);

            }

        }

    }

}

app.config

<?xml version="1.0"?>

<configuration>

<startup>

  </startup><system.serviceModel>

        <bindings>

            <basicHttpBinding>

                <binding name="BasicHttpBinding_IQMS" closeTimeout="00:01:00"

                    openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00"

                    allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard"

                    maxBufferSize="65536" maxBufferPoolSize="524288" maxReceivedMessageSize="65536"

                    messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered"

                    useDefaultWebProxy="true">

                    <readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384"

                        maxBytesPerRead="4096" maxNameTableCharCount="16384" />

                    <security mode="TransportCredentialOnly">

                        <transport clientCredentialType="Ntlm" proxyCredentialType="None"

                            realm="" />

                        <message clientCredentialType="UserName" algorithmSuite="Default" />

                    </security>

                </binding>

                <binding name="BasicHttpBinding_IQTService" closeTimeout="00:01:00"

                    openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00"

                    allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard"

                    maxBufferSize="65536" maxBufferPoolSize="524288" maxReceivedMessageSize="65536"

                    messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered"

                    useDefaultWebProxy="true">

                    <readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384"

                        maxBytesPerRead="4096" maxNameTableCharCount="16384" />

                    <security mode="TransportCredentialOnly">

                        <transport clientCredentialType="Ntlm" proxyCredentialType="None"

                            realm="" />

                        <message clientCredentialType="UserName" algorithmSuite="Default" />

                    </security>

                </binding>

            </basicHttpBinding>

        </bindings>

        <client>

            <endpoint address="http://rg-pc:4799/QMS/Service" binding="basicHttpBinding"

                bindingConfiguration="BasicHttpBinding_IQMS" contract="QMSAPI.IQMS"

                name="BasicHttpBinding_IQMS" behaviorConfiguration="ServiceKeyEndpointBehavior"/>

            <endpoint address="http://rg-pc:4799/ANY/Service" binding="basicHttpBinding"

                bindingConfiguration="BasicHttpBinding_IQTService" contract="QMSAPI.IQTService"

                name="BasicHttpBinding_IQTService" behaviorConfiguration="ServiceKeyEndpointBehavior"/>

        </client>

    <extensions>

      <behaviorExtensions>

        <add name="serviceKeyBehavior" type="MyTestApplication.ServiceKeyBehaviorExtensionElement, MyTestApplication2, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null"/>

      </behaviorExtensions>

    </extensions>

    <behaviors>

      <endpointBehaviors>

        <behavior name="ServiceKeyEndpointBehavior">

          <serviceKeyBehavior/>

        </behavior>

      </endpointBehaviors>

    </behaviors>

    </system.serviceModel>

</configuration>

QMSAPI update works fine, QVS call works, service key too but  qdsService stay nulls

Coudl you help me please ?

Best regards

Regis

Not applicable

Does "QlikView Server Agent" work on 64 Bit machines, as I got the following error?

Failed to interact with service , Exception call stack: System.InvalidOperationException: Cannot open QlikviewServer service on computer 'PAUL-QLIKTECH'. ---> System.ComponentModel.Win32Exception: Access is denied   --- End of inner exception stack trace ---   at System.ServiceProcess.ServiceController.GetServiceHandle(Int32 desiredAccess)   at System.ServiceProcess.ServiceController.Stop()   at QlikView_Server_Agent.Main.InteractWithService(ServiceController Svc)

StefanBackstrand
Partner - Specialist
Partner - Specialist
Author

prh: Yes, it should work just fine. The error in the stack suggest that you don’t have access to the services with the user – if you have UAC on the machine, make sure to run QlikView Server Agent by right-clicking the exe and selecting “Run as Administrator..”. It will also require you to have administrative privileges on the target machine.

/s

Stefan Bäckstrand

Senior Technical Expert, PM

Email: Support@qlik.com<mailto:Support@qlik.com>

qlik.com<http://www.qlik.com/>

The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from any computer.