Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
please explain the qulify and unqualify
reddy
Refer to page No. 323 and 340 of Qlikview reference manual.
Hi,
Qualify statements renames all the fields with the table name prefix which are mentioned in the statement.
QUALIFY *; it can be used above the table name. * is to rename all the field name in the table.
Otherwise u can also specify each field that u wanted to rename.
UNQUALIFY is reverse process of QUALIFY statement.
If u r not using the UNQUALIFY statement after using QUALIFY, it ll rename all fields of all the table below the QUALIFY.
QUALIFY *; //or QUALIFY OrderID, CustomerName;
Orders: //Table Name
LOAD OrderID,
OrderName,
CustomerName,
FROM xxx.xls;
UNQUALIFY *;
If u use * then, ur fields ll be like this: Orders.OrderID
Orders.OrderName
Orders.CustomerName
If not using *, it ll rename oly the fields u have mentioned.
Hope this helps u.
Here's a good way to use QUALIFY and UNQUALIFY to bring in new tables and you want to link on one known field, but you aren't sure whether you will have name clashes with the rest.
QUALIFY *;
UNQUALIFY OrderID;
Orders:
LOAD OrderID,
OrderName,
CustomerName,
FROM xxx.xls;
UNQUALIFY *;
This will result in a table with fields like this:
OrderID
Orders.OrderName
Orders.CustomerName
vey good post. Thank you for give a very clear sample .
Please refer the attached application
Hi,
just to add a little bit out of my own experience:
=> You have to be really careful about those commands: When you have INCREMENTAL LOADs anywhere, for example, putting those commands in the wrong place can have you facing ever-increasing field_names getting longer with every reload
>>> (like [table].[table].[table].[field] etc.) <<<
So it's better to sit back and spend some time thinking what you have (base_data), what you want and what will be the effect of putting those commands in a specific place - and check the outcome right away.
Best regards,
DataNibbler
Nice and helpful post
Hi,
What's the difference between your script and the below one? I did not write UNQUALIFY * at the end.
QUALIFY *;
UNQUALIFY OrderID;
Orders:
LOAD OrderID,
OrderName,
CustomerName,
FROM xxx.xls;
I got it while I was practicing.
UNQUALIFY * is needed at the end of load script, otherwise QUALIFY * is getting applied to script in next tabs as well