cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Post Prodigy
Post Prodigy

How do I replace non-null values in a Merged Queries table?

Hello

 

How do I replace non-null values in a Merged Queries table?

 

Thanks

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted

hi, you could add an additional conditional column, then populate that based on your values being not null. (enter the word null in the condition).  Then drop the original column and rename your new one. 

the line of powerquery that gets created is like this: 

= Table.AddColumn(#"Previous Step Name", "New Column Name", each if [Old Column Name] <> null then "X" else null)

View solution in original post

6 REPLIES 6
Highlighted
Resolver V
Resolver V

I think you'll have to expand your question a little so we can understand the issue

Highlighted
Super User I
Super User I

Hi @UsePowerBI 

 

In Power Query:

Select the column to have values replaced > Go to Transform tab > Select Replace Values > Choose value to be replaced and the required new value.

 

Pete

Highlighted
Community Support
Community Support

@UsePowerBI ,

 

In query editor, click transform-> replace values as below:

1.PNG2.PNG 

 

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.

Highlighted

I want to replace NON-NULL values with X, how do I represent NON-NULL VALUES in that replace form?

 

I cannot enter every single value of the column there individually as they are hundreds.

 

I want to leave NULL values as they are.

 

Can I use a wildcard or something to represent the NON-NULL values?

Highlighted

hi, you could add an additional conditional column, then populate that based on your values being not null. (enter the word null in the condition).  Then drop the original column and rename your new one. 

the line of powerquery that gets created is like this: 

= Table.AddColumn(#"Previous Step Name", "New Column Name", each if [Old Column Name] <> null then "X" else null)

View solution in original post

Highlighted

@UsePowerBI ,

 

Could you please clairfy why you need to replace all the non-null value with null?

 

Regards,

Jimmy Tao

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Community Conference

Microsoft Power Platform Communities

Check out the Winners!

secondImage

Create an end-to-end data and analytics solution

Learn how Power BI works with the latest Azure data and analytics innovations at the digital event with Microsoft CEO Satya Nadella.

Top Solution Authors
Top Kudoed Authors