Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
On May 18th at 10AM EDT we will answer your QlikView questions live. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Incremental load when composite key

I am trying to do an incremental load for a table having composite key. I create a primary_key while loading the incremental portion and also create a primary_key while loading from the qvd. The where not exists(primary_key) check gives the 'Field not found' error.

$(tableName):

LOAD name&surname as $(primaryKeyColumn),

    name,

    surname,

    `modified_date`;

SQL SELECT *

FROM `qv_test`.names

Where $(lastModifiedColumn) > '$(startDate)' and $(lastModifiedColumn) < '$(endDate)';

Concatenate ($(tableName))

LOAD  name&surname as $(primaryKeyColumn),

  name,

  surname,

  `modified_date`

From $(qvdPath)$(tableName).qvd (qvd)

Where not (Exists($(primaryKeyColumn)));

Could you help me with how to get incremental load when there is a composite key.

1 Solution

Accepted Solutions
Not applicable
Author

Hi,

The second load statement should be as follows:

Concatenate ($(tableName))

LOAD  name&surname as $(primaryKeyColumn),

  name,

  surname,

  `modified_date`

From $(qvdPath)$(tableName).qvd (qvd)

Where not Exists($(primaryKeyColumn),name&surname);

Cheers.

View solution in original post

2 Replies
Not applicable
Author

Hi,

The second load statement should be as follows:

Concatenate ($(tableName))

LOAD  name&surname as $(primaryKeyColumn),

  name,

  surname,

  `modified_date`

From $(qvdPath)$(tableName).qvd (qvd)

Where not Exists($(primaryKeyColumn),name&surname);

Cheers.

View solution in original post

Anuhyak1
Contributor III
Contributor III

How do you perform inner join based on which key you have used to remove duplicates for delete logic. Can you the qlikview script file please if possible