Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
In the incremental load for the insert logic my date field is showing as a blank.
Below is the piece of code for this.
$(IncrTimestampAttr) >=to_date('$(vL.Last_Exec_$(TableName))', 'YYYY-MM-DD HH:MI:SS')
AND
$(IncrTimestampAttr) <to_date('$(vL.This_Exec_$(TableName))', 'YYYY-MM-DD HH:MI:SS')
I am passing update date to the variable IncrTimestampAttr.
Do i need to use peek to retrieve for the max value for the variable IncrTimestampAttr.
Can you please suggest in this.
Thanks,
I feel this statement is wrong
$(IncrTimestampAttr) >=to_date('$(vL.Last_Exec_$(TableName))', 'YYYY-MM-DD HH:MI:SS')
AND
$(IncrTimestampAttr) <to_date('$(vL.This_Exec_$(TableName))', 'YYYY-MM-DD HH:MI:SS')
1. How your assigning the variable IncrTimestampAttr
2. For incremental the you need to compare the table field with variable like below
Data_base_Field_name >=$(IncrTimestampAttr) etc.......
Hi Avinash,
We are using the Update Date and we are storing the same Update Date in the variable $(IncrTimestampAttr).
Thanks
Okay for the incremental you need to compare the data base field with variable, not the variable with data base field .
Share the code how your defining the variable
$(IncrTimestampAttr)
share your code/script will help you out
Hi Avinash,
PFB code,
IF wildmatch('$(vEntityType)','*DB*','*SQL*','*ORACLE*','*SYBASE*','*ACCESS*') THEN
IF (ISNULL(QvdCreateTime('$(vQVD_Extract)$(QVDName).QVD')) OR (QvdNoOfRecords ('$(vQVD_Extract)$(QVDName).QVD') = 0) OR ($(LoadTypeInput) = 0)) OR $(vL.Full_Load_Time) THEN
[$(TableName)]:
SQL SELECT
$(Columns)
FROM $(TableName)
Where $(WhereCond)
;
LET vL.Load_Type = 'FULL';
ELSE
[$(TableName)]:
SQL SELECT
$(Columns)
FROM $(TableName)
where
$(WhereCond)
AND
// $(IncrTimestampAttr) >= TO_DATE('$(vL.Last_Exec_$(TableName))')
// AND
// $(IncrTimestampAttr) < TO_DATE('$(vL.This_Exec_$(TableName))')
$(IncrTimestampAttr) >=to_date('$(vL.Last_Exec_$(TableName))', 'YYYY-MM-DD HH:MI:SS')
AND
$(IncrTimestampAttr) <to_date('$(vL.This_Exec_$(TableName))', 'YYYY-MM-DD HH:MI:SS')
;
EXIT SCRIPT;
//*;
We are storing all the value for variables, column names, Table names in the excel.
Thanks.