+ Reply to Thread
Results 1 to 2 of 2

Power BI - Export Data, Turn 0/1 to True/False

  1. #1
    Registered User
    Join Date
    03-08-2020
    Location
    UK
    MS-Off Ver
    365 Business & 365 Family
    Posts
    34

    Power BI - Export Data, Turn 0/1 to True/False

    Hi,

    So after spending a full day playing around with Power BI after never using it before I'm getting the hang of it and have made my first project (attached).

    I've noticed I'm going to need to change the data type on a number of my columns from Numbers which have the values 0,1,2,3,4 to True/False so that 0 will be False and 1,2,3,4 will be True.
    But then this will mean ill need to update some of my Columns I've made that use the following DAX:

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    and that would result in a number.

    But now that I'm having to change the data type on that column I'll need to update the query (the existing one still works but still outputs a number value). How would i do it so:

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    So as long as there's 1 True value then the output will always be True.

    I'm having one of those days where my head is not thinking right as this is probably an easy thing to do

    EDIT: My brain finally kicked in, I've done the following, can you confirm if this is a good way of me doing it or is there a better way?

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Any help would be great.

    Thanks
    Attached Images Attached Images
    Last edited by micky007; 05-06-2020 at 08:56 AM.

  2. #2
    Forum Expert rorya's Avatar
    Join Date
    08-13-2008
    Location
    East Sussex, UK
    MS-Off Ver
    365 Ent SAC
    Posts
    8,885

    Re: Power BI - Export Data, Turn 0/1 to True/False

    It sounds like you just want OR:

    Coca-Cola Original = OR('measure-report'[Coca-Cola Regular 330ml can],'measure-report'[Coca-Cola Regular 500ml pet])
    Rory

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Power Query - calculated true or false show result of table????
    By janljan in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 04-02-2018, 11:23 PM
  2. Accumulate time when true and when false turn it to zero.
    By pedrohern in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-03-2015, 05:02 AM
  3. Accumulate time when true and when false turn it to cero.
    By pedrohern in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 11-02-2015, 12:36 PM
  4. What is best to use for helper cells 0 or 1, typed true or false or =true =false
    By Gingermuppet in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-20-2014, 10:41 PM
  5. [SOLVED] in this TRUE OR FALSE function, i want desired name instead of display true or false
    By vengatvj in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-15-2013, 06:44 PM
  6. [SOLVED] Export to open .csv file a selected cell range conditioned on a true/false in same row
    By BigAl_Qld in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-20-2012, 07:31 PM
  7. how to turn of a series in data sheet of a power point chart using macro
    By chepyalarr in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-02-2006, 03:10 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1