2 Replies Latest reply: Dec 6, 2011 2:33 AM by vince3881 RSS

    Get 'ajax Url' in a QV document

      Hi

       

      I need to get the url in my Qlikview document to catch the parameters of it

      I failed to resolved my problem

      May be somebody have do it and can help

       

      my url looks like

      http://myServer.myDomain.fr/xxxxxx/accessPoint.aspx?open=&id=Local%7CMyFolder/myDocument.qvw&client=ajax&param1=val1ue

       

      Thanks by advance

       

      Vincent

        • Re: Get 'ajax Url' in a QV document
          Miguel Angel Baeyens de Arce

          Hi Vincent,

           

          SubField() will do, and a precedent load will help as well:

           

          Data:
          LOAD SubField(Pairs, '=', 1) AS Name,
               SubField(Pairs, '=', 2) AS Value;
          LOAD SubField(SubField('http://myServer.myDomain.fr/xxxxxx/accessPoint.aspx?open=&id=Local%7CMyFolder/myDocument.qvw&client=ajax&param1=val1ue', '?', 2), '&') AS Pairs
          AUTOGENERATE 1;
          

           

          This dummy example based on your url does the following:

          1. The first load takes the part on the right of the "?" where the values are and
          2. Takes each of the pairs between "&" (name=value)
          3. Then the preceding load takes the part on the left of the "=" as the parameter name and the right as the parameter value.

           

          This will work regardless the number of parameters and urls you have, resulting in three fields, Name, Value and Pairs.

           

          Is this what you are looking for?

           

          Miguel