Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Announcements
Coming your way, the Qlik Data Revolution Virtual Summit. October 27-29. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Contributor III
Contributor III

Help with creating SCD table

Hello
I need your help to create the second table from the first table.
I try to duplicate the dates on all subsequent records, until the next date appears and so on ...

Thanks, Adiel

 

Capture 1.PNG

Labels (3)
1 Solution

Accepted Solutions
Highlighted
MVP & Luminary
MVP & Luminary

Like this for example:

LOAD
    Line,
    CustomerID,
    Alt(IsEnter,0) as IsEnter,
    If(Len(Trim(EnterDate))>0, EnterDate, Peek(EnterDate)) as EnterDate
FROM
     ...source table...
    ;

talk is cheap, supply exceeds demand

View solution in original post

2 Replies
Highlighted
MVP & Luminary
MVP & Luminary

Like this for example:

LOAD
    Line,
    CustomerID,
    Alt(IsEnter,0) as IsEnter,
    If(Len(Trim(EnterDate))>0, EnterDate, Peek(EnterDate)) as EnterDate
FROM
     ...source table...
    ;

talk is cheap, supply exceeds demand

View solution in original post

Highlighted
Contributor III
Contributor III

Thanks !!!