Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Get list of QUALIFIED fields

Hi.

Is it possible to know wich fields are currently QUALIFIED ?

So, is there any system variable wich store the fields we actually want to QUALIFY.

i.e.:

UNQUALIFY *;

DATA:

QUALIFY name, society;

LOAD id, name, society FROM qvd_file;

Any treatment {

     here, I want to know how my field are called; so wich ones have a prefix table name.

};

1 Solution

Accepted Solutions
Anil_Babu_Samineni

Check in data model which field are extending to Table like TableName.FieldName ...

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful

View solution in original post

3 Replies
Anil_Babu_Samineni

Check in data model which field are extending to Table like TableName.FieldName ...

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
rwunderlich
Partner Ambassador/MVP
Partner Ambassador/MVP

I don't think there is any way in script to detect what the current qualify is, or to determine what has been qualified already.

-Rob

Anonymous
Not applicable
Author

Thanks for your suggestion.

Effectively, I've make an information table, browsing the data model, using the functions NoOfTables() and NoOfFields().

It's not very perfect, because it may have some errors, as a fieldName wish has been renamed; but I can't do better.

So:

DATA:

LOAD '' as tableName, '' as fieldName, '' as isQualified

autogenerate(0);

for i = 0 to NoOfTables() - 1

    for j = 1 to NoOfFields(TableName($(i)))

          let vTableName = TableName($(i));

          let vFieldName = FieldName($(j), TableName($(i)));

          let vIsQualified = if (SubField(vFieldName, '.', 1) = vTableName, true(), false());


          LOAD '$(vTableName)' as tableName, '$(vFieldName)' as fieldName, '$(vIsQualified)' as isQualified

          autogenerate(1);

    next j;

next i;

Regards.