I have a table and I want to create 5 rows with respect to id and week. for example
input table
id week value
1 2022-W1 200
2 2022-W3 500
2 2022-W6 600
output
id week value
1 2022-W1 200
1 2022-W2 200
1 2022-W3 200
1 2022-W4 200
1 2022-W5 200
2 2022-W3 500
2 2022-W4 500
2 2022-W5 500
2 2022-W6 600
2 2022-W7 600
2 2022-W8 600
2 2022-W9 600
2 2022-W10 600
Explanation -
for id = 1, w1 -> add 5 rows incremental to week
1 2022-W1 200
1 2022-W2 200
1 2022-W3 200
1 2022-W4 200
1 2022-W5 200
There are 2 rows for id = 2, (w3, and w6). for w3, there will be only 3 rows because 4 rows should be w6 and w6 is already present in the table.
2 2022-W3 500
2 2022-W4 500
2 2022-W5 500
for id=2, w6 -> add 5 rows incremental to week
2 2022-W6 600
2 2022-W7 600
2 2022-W8 600
2 2022-W8 600
2 2022-W8 600
