4 Replies Latest reply: Sep 10, 2013 5:52 AM by Varun Prakash Paulraj RSS

    Incremental load using QVC - Oracle DB

    Anitha Shivalingappa

      Hi,

       

      Am getting error while trying to setup incremental load using qlikview components. suggest me to fix this. connecting oracle DB, for SQL DB its working fine.

       

      Error.jpg

        • Re: Incremental load using QVC - Oracle DB
          Tresesco B

          It seems that there is a format issue. please check if your date/timestamp format(withing quotes) is similar to the one in database.

            • Re: Incremental load using QVC - Oracle DB
              Perumal Ayyappan

              Hi

               

              Try this code

               

              Select  *

              FROM Table1 b where

              to_date(b.last_modified_dt, 'dd/mm/yyyy hh:mi PM')

              <=to_date('02/04/2013 6:58 PM', 'dd/mm/yyyy hh:mi PM');

                • Re: Incremental load using QVC - Oracle DB
                  Anitha Shivalingappa

                  thanks for your response. the format is same

                   

                  am using qvs file and calling the incremental function. the script is like this..

                   

                  SET Qvc.Loader.v.QvdDirectory='F:\IAS_DB\Data';

                  LET Qvc.Loader.v.BaseValue = num (MakeDate (2013, 01, 01));

                  SET Qvc.Loader.v.DatabaseDatetimeMask = 'M/D/YYYY h: mm:ss TT';

                   

                  // Calling parameters are Tablename, UpdateColumn, QVD_PrimaryKey.CALL Qvc.IncrementalSetup ('VIW_MONTHLY_INCIDENT_NODATE', 'LASTMDFDDATE', 'IND_CALL_NO');
                  Directory;
                  [$(Qvc.Loader.v.Tablename)]:

                   

                  LOAD *;
                  SQL SELECT *
                  FROM NEWWCCC."VIW_MONTHLY_INCIDENT_NODATE"
                  WHERE
                  $(Qvc.Loader.v.IncrementalExpression);

                   

                  Call Qvc.Log ('$(Qvc.Loader.v.Tablename) loaded, rows=' &

                  Num (NoOfRows ('$(Qvc.Loader.v.Tablename)'), '#,##0'));

                   

                  CALL Qvc.IncrementalStore

                   

                  CALL Qvc.Cleanup;

                   

                   

                  Also i tried the below script also but its not working. help me out to fix this..

                   

                  SET TimestampFormat='M/D/YYYY h:mm:ss[.fff] TT'; Let vThisExecTime=Now();

                  Let vQvd=isnull(QvdCreateTime([F:\IAS_DB\Data\VIW_MONTHLY_INCIDENT_NODATE.qvd]));

                  if(vQvd=-1) then

                  VIW_MONTHLY_INCIDENT_NODATE:
                  SQL SELECT *
                  FROM NEWWCCC."VIW_MONTHLY_INCIDENT_NODATE";

                  Else


                  SQL SELECT *
                  FROM NEWWCCC."VIW_MONTHLY_INCIDENT_NODATE" where Trunc(LASTMDFDDATE) >=
                  $(vLastExecTime) and Trunc(LASTMDFDDATE) <$(vThisExecTime);


                  Concatenate

                  LOAD * FROM
                  [..\Data\VIW_MONTHLY_INCIDENT_NODATE.qvd]
                  (
                  qvd) where not Exists(id,id);
                  ENDIF

                   


                  Store VIW_MONTHLY_INCIDENT_NODATE into ..\Data\ VIW_MONTHLY_INCIDENT_NODATE.qvd;

                   

                  DROP Table VIW_MONTHLY_INCIDENT_NODATE;

                   

                   

              • Re: Incremental load using QVC - Oracle DB
                Varun Prakash Paulraj

                facing this same problem please post the answer

                 

                 

                 

                 

                Regards