Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
Hello,
I have already worked with xml field, using the add column, extract, then text between delimiters, and it worked fine.
The situation is more complicated with the input data, I have.
Imagine that I have a file with let's say ten columns and many rows.
Among the fields, one is an xml field.
For example, for row one I have the following Columns
A B C D E F G H I J and the column F is an Xml Field.
This xml field has structure like the following
L1 M1 N1 O1 P1 Q1 R1 S1 row1 row2 row3..., row18
So if I expand this field, at the end I should have something like that.
A1 B1 C1 D1 E1 L1 M1 N1 O1 P1 Q1 R1 S1 row1 G1 H1 I1 J1
A1 B1 C1 D1 E1 L1 M1 N1 O1 P1 Q1 R1 S1 row2 G1 H1 I1 J1
....
A1 B1 C1 D1 E1 L1 M1 N1 O1 P1 Q1 R1 S1 row1 G1 H1 I1 J1
Also, row1 has let's say five different fields and value as well so it give, if we expand the row content:
A1 B1 C1 D1 E1 L1 M1 N1 O1 P1 Q1 R1 S1 val11 val12 val13 val14 val15 H1 I1 J1
A1 B1 C1 D1 E1 L1 M1 N1 O1 P1 Q1 R1 S1 val21 val22 val23 val24 val25 H1 I1 J1
...
A1 B1 C1 D1 E1 L1 M1 N1 O1 P1 Q1 R1 S1 val181 val182 val183 val184 val185 H1 I1 J1
Now imagine that the second row is A2 B2 C2 D2 E2 F2 G2 H2 I2 J2 and that the F2 xml field contains 10 rows with 5 value each it will give
A2 B2 C2 D2 E2 L2 M2 N2 O2 P2 Q2 R2 S2 val11 val12 val13 val14 val15 H2 I2 J2
A2 B2 C2 D2 E2 L2 M2 N2 O2 P2 Q2 R2 S2 val21 val22 val23 val24 val25 H2 I2 J2
...
A2 B2 C2 D2 E2 L2 M2 N2 O2 P2 Q2 R2 S2 val101 val102 val103 val104 val105 H2 I2 J2
and so on.
How can I use power bi to expand my input file in such manner?
Thanks in advance for you help
Solved! Go to Solution.
@Anonymous ,
Generally, about how to expand columns in power query, I would suggest you refer to the third-party blog written by Chirs.
https://blog.crossjoin.co.uk/2014/05/21/expanding-all-columns-in-a-table-in-power-query/
Community Support Team _ Jimmy Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@Anonymous ,
Generally, about how to expand columns in power query, I would suggest you refer to the third-party blog written by Chirs.
https://blog.crossjoin.co.uk/2014/05/21/expanding-all-columns-in-a-table-in-power-query/
Community Support Team _ Jimmy Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
117 | |
84 | |
49 | |
38 | |
28 |
User | Count |
---|---|
185 | |
73 | |
73 | |
50 | |
42 |