Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
doespirito
Creator
Creator

creating a table detail from table

Hello,
From a table 1, which contains a list of journals and a field representing the number of pages of these journals, I wish to create a table 2 which contains for each journal 1 record per page with a numbering of these pages.
I tried with the peek function but I can't do it.
can you help me?
THANKS
Arnault

doespirito_0-1706538972999.png

 

Labels (1)
1 Solution

Accepted Solutions
Or
MVP
MVP

I'm not sure what the pages are supposed to represent, but if you're trying to create N records per original record, have a look at using Load ... While with IterNo(), e.g.

Load A, B, C, IterNo() as D From SomeTable

While IterNo() <C;

 

https://help.qlik.com/en-US/qlikview/May2023/Subsystems/Client/Content/QV_QlikView/Scripting/Counter...

View solution in original post

4 Replies
Or
MVP
MVP

I'm not sure what the pages are supposed to represent, but if you're trying to create N records per original record, have a look at using Load ... While with IterNo(), e.g.

Load A, B, C, IterNo() as D From SomeTable

While IterNo() <C;

 

https://help.qlik.com/en-US/qlikview/May2023/Subsystems/Client/Content/QV_QlikView/Scripting/Counter...

qv_testing
Specialist II
Specialist II

Try this

LOAD Date,
           MediaSAP,
           EditionSAP,
           NBPagesSAP2,
           IterNo() as Sequence
FROM
[C:\Data.xlsx](ooxml, embedded labels, table is Sheet3)
while IterNo() <=NBPagesSAP2;

doespirito
Creator
Creator
Author

Thank you so much.
it works great with iterno() and while.
Good day !

doespirito
Creator
Creator
Author

Thank you for taking the time to respond to me. I used the first solution and I will try to test yours