#1 2011-10-13 15:27:30

vikram
Guest

Incremental load

Hi Team,

I have a table where it needs to have unique key each time when it is inserting a record on every ETL process. How do I achieve this in jasper ETL tool?
For example if it inserts 1,2,3 at the first run my next run should insert 4,5,6 as a key for the same set of records.

I tried NUMERIC function but it is unable to fetch a result.

Regards,
vikki

#2 2011-10-13 16:10:45

avdbrink
Member
Company: Conspect Consulting & ICT
Registered: 2010-11-08
Posts: 360
Website

Re: Incremental load

Hi,

You could use a lookup for the last key in the table and use this as parameter to the numeric.sequence function.

Regards,
Arno

Offline

#3 2011-10-19 07:12:01

vikram
Guest

Re: Incremental load

Hey,

Thanks lot for the update. But since its taking the last value from the look up for the next sequence there are two records getting the same key.

For example if the last value is var=5.  In numeric function incremental starts from 5 again i.e Numeric sequence("s1",var,1) .So the 2nd run first value gets key as 5.
But i need it to be started with 6. How do i achieve this?

Regards,
Vikki

#4 2011-10-19 08:47:15

djugal
Member
Registered: 2011-06-16
Posts: 229
Website

Re: Incremental load

You can add 1 to the variable you get from the lookup

Offline

#5 2011-10-19 12:10:32

vikram
Guest

Re: Incremental load

How do i add to the variable?
'+' will append the value dont add :-(

Board footer

Powered by FluxBB