Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
madhubabum
Creator
Creator

Incremental logic help

Hi All,

I am having the following code to implement incremental logic with out date field ,

Table1:

LOAD * INLINE [

    ID, Amount

    1, 100

    2, 200

    3, 300,

  4, 401

];

Concatenate(Table1)

LOAD * INLINE [

    ID, Amount

    4, 400

    4, 402

    5, 500

    5, 502

    5, 510

] where not  Exists (ID);

OUTPUT:

ID, Amount

1, 100

2, 200

3, 300

4, 401

5, 500


Expected Result :

ID, Amount

1, 100

2, 200

3, 300

4, 401

5, 500

5, 502

5, 510     (Means we need to display table 2 records, duplicates records as well )

Regards,

Madhu

1 Solution

Accepted Solutions
MK_QSL
MVP
MVP

Table1:

LOAD *, ID as TempID INLINE [

    ID, Amount

    1, 100

    2, 200

    3, 300,

  4, 401

];

Concatenate(Table1)

LOAD * INLINE [

    ID, Amount

    4, 400

    4, 402

    5, 500

    5, 502

    5, 510

] where not  Exists (TempID, ID);

Drop Field TempID;

View solution in original post

4 Replies
Chanty4u
MVP
MVP

jst add

where not  Exists (ID)>0;

Chanty4u
MVP
MVP

is this?

tot.PNG

madhubabum
Creator
Creator
Author

Thanks  for your reply,

ID Amount

1  100

2  200

3  300

4  401

5  500

5  502

5  510

Note : Update on table1

regards,

madhu

MK_QSL
MVP
MVP

Table1:

LOAD *, ID as TempID INLINE [

    ID, Amount

    1, 100

    2, 200

    3, 300,

  4, 401

];

Concatenate(Table1)

LOAD * INLINE [

    ID, Amount

    4, 400

    4, 402

    5, 500

    5, 502

    5, 510

] where not  Exists (TempID, ID);

Drop Field TempID;