cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
jaykilleen Regular Visitor
Regular Visitor

Convert Integer to Logical

PowerBI seems to have a hard time converting "1" and "0" to TRUE and FALSE.

 

Is the best way here to convert to Whole Number first then add another step to convert to True/False??

 

 

Expression.Error: We couldn't convert to Logical.
Details:
    1
1 ACCEPTED SOLUTION

Accepted Solutions
Ross73312 Super Contributor
Super Contributor

Re: Convert Integer to Logical

Either through Power Query or DAX i'd make another column.  The formula would just be [Value] = 1.  That way if [Value] is 0, you will get a false, and if it is 1 you will get a true.


   

              Did I answer your question? Mark my post as a solution!
       

Proud to be a Datanaut!


   


View solution in original post

2 REPLIES 2
Ross73312 Super Contributor
Super Contributor

Re: Convert Integer to Logical

Either through Power Query or DAX i'd make another column.  The formula would just be [Value] = 1.  That way if [Value] is 0, you will get a false, and if it is 1 you will get a true.


   

              Did I answer your question? Mark my post as a solution!
       

Proud to be a Datanaut!


   


View solution in original post

Highlighted
Community Support Team
Community Support Team

Re: Convert Integer to Logical

@jaykilleen,

 

I agree with the comment above. You could also nest type transformation in one step by using Advanced Editor.

Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
October 2019 Community Highlights

October 2019 Community Highlights

October was a busy month in the community. Read the recap article to learn about some of the events and content.

New Badges

Incoming: New and Improved Badges

Exciting news: We've given our badges an overhaul and added brand news ones.

Ask Amir Anything

Exclusive LIVE Community Event No. 2 – Ask Amir Anything

Next in our Triple A series: Ask Amir Netz questions about the latest updates, features and future.

Analytics in Azure virtual event

Analytics in Azure virtual event

Experience a limitless analytics service built to ingest, prep, manage, and serve data for immediate use in Power BI.

Users Online
Currently online: 136 members 1,557 guests
Please welcome our newest community members: