6 Replies Latest reply: Jan 16, 2014 9:35 AM by Gomti Mehta RSS

    Can't get around understanding different types of load

      What is the difference between following types of load

       

      TableName1:

      Load a,b,c;

      SQL select * from ViewTable1;

       

      -------------------------------------------------------------------------------------------------------------------------------------------------------

      TableName2:

      a,b,c,d;

      SQL select * from ViewTable2;

      Concatenate(table1)

       

      Load distinct

      a,b,c,d,e,f

      Resident Table2;

       

      I have a report and I am not able to understand these load statements. I went through the documentation and it hasnt helped much.

        • Re: Can't get around understanding different types of load
          Clever Anjos

          I´m assuming that

          Concatenate(table1) is Concatenate(TableName1), please let me know if I´m wrong...


          TableName1:
          Load a,b,c;
          SQL select * from ViewTable1;
          // will create one table with 3 fields called TableName1
          
          TableName2:
          LOAD a,b,c,d;
          SQL select * from ViewTable2;
          // Will create another table with 4 fields called TableName2
          
          Concatenate(TableName1)
          Load distinct
          a,b,c,d,e,f
          Resident Table2;
          //Will append to TableName1, adding more rows and 3 more fields
          
          • Re: Can't get around understanding different types of load
            jagan mohan rao appala

            Hi,

             

            Please find explanation below

             

            TableName1:

            Load a,b,c;                                 -- This is called a precedent load, even you have n number of fields in table you are                                                          loading only columns a, b, c; 

            SQL select * from ViewTable1;     -- Loads all columns in ViewTable1;

             

            The above statement can also be achieved like this

             

            TableName1:

            SQL select a, b, c from ViewTable1;  


            -- Note: Never use * in Select Query, because loading all fields in the table which are not used in the dashboard will raise to performance issues also the loading time is more.

             

            -------------------------------------------------------------------------------------------------------------------------------------------------------

            TableName2:

            Load               -- I think missed Load Keyword

            a,b,c,d;          -- This is called a precedent load, even you have n number of fields in table you are                                                          loading only columns a, b, c, d;

            SQL select * from ViewTable2;

             

             

            Concatenate(TableName1)     -- Merges TableName2 into TableName1

            Load distinct                             -- Distinct will suppress duplicate values

            a,b,c,d                                   -- Fields e and f should not be here because it is not defined in above Load statement.

            Resident TableName2;

             

            Hope this helps you.

             

            Regards,

            Jagan.