Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
in a sorted (ascending) field I have values in seconds. In my load I want to set the minimum value of that field to zero. The following values should then be represented by the difference to the preceding value. Example:
I have:
Time |
---|
12 |
13 |
15 |
17 |
18 |
I want a new field Duration based on Time-Field:
Duration |
---|
0 |
1 |
2 |
2 |
1 |
How to calculate this during load?
Thanks,
Hamid
What about this:
Table_Temp:
Load
Time,
If(IsNull(Peek(Time)),0,Time-Peek(Time)) as Duration;
Load * Inline [
Time
12
13
15
17
18
];
Table:
NoConcatenate
Load * Resident Table_Temp Where Duration >=0;
Drop Table Table_Temp;
Hey Saiyed,
Is your question solved? Please, let us know how it goes.
Cheers
Hey Saiyed,
Any news about it? If this thread is solved, please let us know by marking the correct answer.
Cheers