3 Replies Latest reply: Jun 20, 2011 10:35 AM by At titude RSS

    Storing only the filtered records in the existing QVD. Based on the Max(LoginDate) from existing QVD.

      Hi All

       

      Can some one please help me out with the following requirement which is there in between the block(//////////). It is little urgent!

       

      Login:
      
      LOAD @1 as LoginDate, 
           @2 as User, 
           @3 as Product
      FROM
      [C:\Status.txt]
      (txt, codepage is 1252, no labels, delimiter is ',', msq);
      
      Store Login into Login.qvd (qvd);
      
      drop table Login;
      
      Login: 
      
      Select LoginDate, User, Product
      FROM
      [C:\Login.qvd]
      (qvd);
      
      ///////////////////////// Requirement /////////////////////////
      1. Using the Max(LoginDate) from the Login. I need to filter data which has to be concatenated with the Login.qvd from Status.txt
      2. Only those records in which LoginDate > Max(LoginDate){Which is loaded from the above qvd file} should store in to the existing qvd(Login.qvd)
      3. For the above 2 requirement what should be there in the below "WHERE" condition?
      ///////////////////////////////////////////////////////////////
      
      CONCATENATE
      
      Login:
      
      LOAD @1 as LoginDate, 
           @2 as User, 
           @3 as Product
      FROM
      [C:\Status.txt]
      (txt, codepage is 1252, no labels, delimiter is ',', msq)
      WHERE ???;