Forum Discussion
hamzashafiq
3 years agoKudo Collector
Insert 12 Rows for each ID in Power Query
Hey Guys, I have a dataset, I want to insert 12 rows for each ID in the table using Power Query and insert blank in other records except ID. How can I do that? Data: ID Month Year Sales ...
- 3 years ago
Ritaf1983
3 years agoSuper User
HI hamzashafiq
In order to achieve the desired result, follow these steps
1. Load the IDs and months table
2. Append it to your sales table
3. Add to the result table column concatenates date with ID
4. Remove Duplicates (based on the merged column)
5. Replace null with zero on the sales column :
5. Remove unnecessary column ("merged")
6. Uncheck "enable load" on unnecessary table
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
hamzashafiq
3 years agoKudo Collector
Thanks Ritaf1983 for the solution but the problem is that, how to load the IDs and Months data, that ID is not static. We have thousands of Ids.