Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
julioarriaga
Creator II
Creator II

How do I use a script created field tag in an expression?

Hi, I want to know if I can use a tag created as it is shown in the code in an expression.

Thanks and kind regards.

 

Table1:
LOAD * INLINE [A,B
2,3
4,5];

TAG FIELD A With 'LA';

 

Labels (1)
3 Replies
rwunderlich
Partner Ambassador/MVP
Partner Ambassador/MVP

As far as I know, this is not possible. There is no expression function that returns tags. 

If it fits your use case, you could possibly load tags into fields usable by your expression.  Is this Qlik Sense or QlikView?

-Rob
http://masterssummit.com
http://qlikviewcookbook.com
http://www.easyqlik.com

julioarriaga
Creator II
Creator II
Author

It is Qlik Sense. How could I load these tags into fields?

Thanks for the response.

rwunderlich
Partner Ambassador/MVP
Partner Ambassador/MVP

You could load them by interrogating the tags from the app using the API.  That is probably going to limit you to the tags available in the last saved version of the app or when your collector runs.  If you don't have any idea about writing this yourself an immediate solution would be to borrow the QsAppMetadataConnector from QS Document Analyzer. 

1. Install QS Document Analyzer if not already installed. 

2. Add a QsAppMetadata connection to your app and configure it to point to your app. 

3. Use the standard select wizard to generate a load statement for the Fields table like this:

LIB CONNECT TO 'appmeta';

LOAD "FieldName",
Trim(SubField(FieldTags, ',')) as [Field Tag];
SQL SELECT "FieldName",
FieldTags
FROM "Fields";

The QS Document Analyzer installer does not support install on QS Enterprise, but if you need the connector on your server you only need to copy the QsAppMetadataConnector folder from your desktop connectors to the Server connectors folder.

-Rob
http://masterssummit.com
http://qlikviewcookbook.com
http://www.easyqlik.com