Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hi community,
We used the following SQL statement to bring a column from the table TBL1211 into TBL2211 through the table TBL1201.
SELECT
DATA.TBL2211.SDMCU AS "CC (MCU)",
( SELECT DATA.TBL1211.KAVL
FROM DATA.TBL1211
INNER JOIN
DATA.TBL1201 ON DATA.TBL1211.KAGID = DATA.TBL1201.CMGID
WHERE DATA.TBL1211.KAPEL = '60'
AND DATA.TBL1201.CMDC = DATA.TBL2211.SDDC
AND DATA.TBL1201.CMDT = DATA.TBL2211.SDDT
AND DATA.TBL1201.CMLN = DATA.TBL2211.SDLN
AND ROWNUM <= 1
) AS "(FLTR 60)"
FROM
DATA.TBL2211
Now we decided to Extract each table alone and then do the merges in Power Query. I did the merging, but i have a problem. Some elements are duplicates (Same columns we used for join : SDDC, SDDT and SDLN, but they have 2 KAGID), now we fixed this issue when we used SQL by using the function ROWNUM. So, i need an equivalent of this function in Power Query.
Thank you.
The safest way to do this in Power Query is to use "Group By" or to have an index column or both.
Word of warning: Merge operations in Power Query are expensive. It would be preferable to continue to do these in the data source.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
15 | |
11 | |
8 | |
8 | |
7 |
User | Count |
---|---|
15 | |
13 | |
9 | |
6 | |
6 |