5 Replies Latest reply: Mar 6, 2012 4:14 PM by Vladimir Kostochka RSS

    LOAD from QVD / Duplicate rows in QVD vs. SQL

      I have a much large QVW with multiple QVD references and I recently noticed that all the fact tables have duplicate rows when I load data from the QVD.

      I created this quick script to simulate a typical QVD Store and load process. The SQL statement fetches one record from a SQL server table but as soon as I use the LOAD * statement, QV says there are two rows in the table.

      If I add the DISTINCT clause to make it LOAD DISTINCT * there is only one row BUT why is this necessary. Do you always need to put DISTINCT in the LOAD statement from a QVD?

      TBLRECORDS:

       

       



       

       



      SQL SELECT * from SERecords where ID = 3165409;

      STORE

       

      TBLRECORDS INTO TBLRECORDS.QVD (qvd);

       

       

      LOAD * FROM TBLRECORDS.QVD (qvd);

       

       

       

       

      Thanks, Pete

       

       

       

       

      Thanks, Pete

       

       

       

       

      Thanks, Pete