Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
| INPUT- |
| | channel | code |
| |----------|----------| |
| | SMS | Sent | |
| | SMS | Del | |
| | WA | Sent | |
| | WA | Del | |
| | Email | Sent | |
| | Email | Del | |
| |(null) | UEF | |
| OUTPUT- |
| | channel | code |
| |----------|----------| |
| | SMS | Sent | |
| | SMS | Del | |
| | WA | Sent | |
| | WA | Del | |
| | Email | Sent | |
| | Email | Del | |
| |SMS | UEF | |
| |WA | UEF | |
| |Email | UEF | |
Solved! Go to Solution.
Hi @crUzo ,
Thanks for reaching out to the Microsoft fabric community forum.
I’ve gone ahead and reproduced your scenario in Power BI, and I’m glad to confirm that the output matches exactly as per your expected result. The logic successfully replaces the null values in the channel column by generating new rows with all distinct non-null channel values for the given code.
For your reference, below is the DAX I used to create the final output table:
daxCopyEditFinalTable =
VAR __channels =
FILTER( DISTINCT( 'Table'[channel] ), [channel] <> BLANK() )
VAR __nullCodes =
DISTINCT( SELECTCOLUMNS( FILTER( 'Table', [channel] = BLANK() ), "code", [code] ) )
VAR __BaseTable =
FILTER( 'Table', [channel] <> BLANK() )
VAR __AddTable =
SELECTCOLUMNS(
GENERATE( __channels, __nullCodes ),
"channel", [channel],
"code", [code]
)
VAR __Result =
UNION( __BaseTable, __AddTable )
RETURN
__Result
I've also attached the .pbix file for your reference so you can check and test the setup directly in your environment.
If the response has addressed your query, please Accept it as a solution and give a 'Kudos' so other members can easily find it
Best Regards,
Sreeteja
Community Support Team.
Hi @crUzo ,
Thanks for reaching out to the Microsoft fabric community forum.
I’ve gone ahead and reproduced your scenario in Power BI, and I’m glad to confirm that the output matches exactly as per your expected result. The logic successfully replaces the null values in the channel column by generating new rows with all distinct non-null channel values for the given code.
For your reference, below is the DAX I used to create the final output table:
daxCopyEditFinalTable =
VAR __channels =
FILTER( DISTINCT( 'Table'[channel] ), [channel] <> BLANK() )
VAR __nullCodes =
DISTINCT( SELECTCOLUMNS( FILTER( 'Table', [channel] = BLANK() ), "code", [code] ) )
VAR __BaseTable =
FILTER( 'Table', [channel] <> BLANK() )
VAR __AddTable =
SELECTCOLUMNS(
GENERATE( __channels, __nullCodes ),
"channel", [channel],
"code", [code]
)
VAR __Result =
UNION( __BaseTable, __AddTable )
RETURN
__Result
I've also attached the .pbix file for your reference so you can check and test the setup directly in your environment.
If the response has addressed your query, please Accept it as a solution and give a 'Kudos' so other members can easily find it
Best Regards,
Sreeteja
Community Support Team.
Hi @crUzo ,
Just wanted to check if you had the opportunity to review the suggestion provided?
If the response has addressed your query, please Accept it as a solution and give a 'Kudos' so other members can easily find it.
Thank you.
Hi @crUzo ,
Just wanted to check if you had the opportunity to review the suggestion provided? If so, please mark the helpful reply and Accept it as the solution . This will be helpful for other community members who have similar problems to solve it faster.
Hi @crUzo ,
I hope the information provided above assists you in resolving the issue. If you have any additional questions or concerns, please do not hesitate to contact us. We are here to support you and will be happy to help with any further assistance you may need.
@crUzo Maybe:
Table1 =
VAR __Channels = FILTER( DISTINCT( 'Table'[channel] ), [channel] <> BLANK() )
VAR __nullCodes = DISTINCT( SELECTCOLUMNS( FILTER( 'Table', [channel] = BLANK() ), "code", [code] ) )
VAR __BaseTable = FILTER( 'Table', [channel] <> BLANK() )
VAR __AddTable = SELECTCOLUMNS( GENERATE( __Channels, __nullCodes ), "channel", [channel], "code", [code] )
VAR __Result = UNION( __BaseTable, __AddTable )
RETURN
__Result
Hi @crUzo,
Could you please provide more details about your request so that it's easy to understand. The provided deatails are not enough to address.
I want to replace null values from channed to SMS, WA and EMAIL in front for UEF in code
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 57 | |
| 43 | |
| 41 | |
| 22 | |
| 17 |
| User | Count |
|---|---|
| 186 | |
| 116 | |
| 94 | |
| 64 | |
| 45 |