11 Replies Latest reply: Dec 7, 2016 8:30 AM by Roland Goeschl RSS

    qualify and unqualify

      please explain the qulify and unqualify

       

      reddy

        • qualify and unqualify

          Refer to page No. 323 and 340 of Qlikview reference manual.

          • qualify and unqualify

            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.

            • Re: qualify and unqualify
              David White

              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

              • Re: qualify and unqualify
                Venkat Reddy Palla

                Please refer the attached application

                  • Re: qualify and unqualify
                    Friedrich Hofmann

                    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

                  • Re: qualify and unqualify
                    Kuldeep Choudhary

                    Nice and helpful post

                    • Re: qualify and unqualify
                      Roland Goeschl

                      Hello!

                      Is ist possible to rename the unqualified OrderId? I tried it but it does not work!

                       

                      QUALIFY *;

                      UNQUALIFY OrderID;

                       

                      Orders:   

                           LOAD OrderID AS TestOrderID, // this TestOrderID exists in another Table and should be a key

                                     Order Name,

                                     CustomerName,

                           FROM xxx.xls;

                       

                       

                      Thank you!