Don't miss your chance to take the Fabric Data Engineer (DP-700) exam on us!
Learn moreWe've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now
Hello, could someone assist me with the DAX commands needed to duplicate rows in a table? The command should reference a column that has a count greater than 1, duplicating the rows according to the count value. Thank you.
Solved! Go to Solution.
Hi @jwb3d ,
Can you please elaborate a little bit more on the requirements and supply some example?
But based on the overall understanding believe this is better done using Power Query and not DAX, but if you can share the example is easier to give you the correct approach.
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em PortuguêsHi @jwb3d ,
Can you please elaborate a little bit more on the requirements and supply some example?
But based on the overall understanding believe this is better done using Power Query and not DAX, but if you can share the example is easier to give you the correct approach.
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em PortuguêsI need rows which have count column > 1 to be duplicated by the number of times the count represents.
See the image below.
Hi @jwb3d
For this you should use the Power querry because you cannot duplicata tows on a table already loaded só to use dad you would need to create a new table.
On Power query add a column with the followinf code
{1..[Count]}
This Will generate a list of values starting at 1 and ending in the number of the count inside the cell that you can then expand creating a repeted row for each value.
Then you can delete that new column
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em PortuguêsIf you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 9 | |
| 8 | |
| 3 | |
| 2 | |
| 2 |
| User | Count |
|---|---|
| 23 | |
| 14 | |
| 10 | |
| 6 | |
| 5 |