Results 1 to 5 of 5

Thread: Article: Using HASONEVALUE in a DAX IF statement

  1. #1
    Administrator Ken Puls's Avatar
    Join Date
    Mar 2011
    Location
    Nanaimo, BC, Canada
    Posts
    2,225
    Articles
    57
    Blog Entries
    14
    Excel Version
    Excel Office 365 Insider

    Article: Using HASONEVALUE in a DAX IF statement



    Register for a FREE account, and/
    or Log in to avoid these ads!

    Ken Puls, FCPA, FCMA, MS MVP (Excel)

    Learn to Master Your Data at the Power Query Academy (the world's most comprehensive online Power Query training) or with my book M is for Data Monkey!

    Main Site: http://www.excelguru.ca -||- Blog: http://www.excelguru.ca/blog -||- Forums: http://www.excelguru.ca/forums
    Check out the Excelguru Facebook Fan Page -||- Follow Me on Twitter

    If you've been given VBA code (a macro) for your solution, but don't know where to put it, CLICK HERE.

  2. #2
    hi ken,

    this is an excellent article. I have been looking all over for an explanation of HASONEVALUE. This will help me complete some of the reports i was building for finance myself.

    Thanks and Regards
    Vineeth

  3. #3

    Formula guidance request

    Hi Ken,
    Really enjoyed your video at PowerPivot School. Thank you for great, detailed instructions. This post is also very illuminating and useful. One quick question.... the formula
    IF(VALUES(tblCOA[AccGroup])= "Expenses",-1,-1)
    should it not be IF(VALUES(tblCOA[AccGroup])= "Expenses",-1,1)
    this seems to be the case the first time it was introduced but then uses -1 in second argument, for which I didn't understand the logic/reasoning, your guidance would be most appreciated.

    Many thanks.... and keep up the good work.

    Regards,
    Mubbasher.

  4. #4
    Neophyte amit4blog's Avatar
    Join Date
    Dec 2013
    Location
    India
    Posts
    3
    Articles
    0
    Hi Ken,

    It's a great post. I am looking some extra ordinary article, which i found here.Thanks for publishing.

  5. #5
    Hi Ken

    Like others I found your post very helpful - thanks.

    One thing I am having a bit of trouble with is taking this down to another level ie the next account sub group. For example, what if "Alcoholic Beverages" was broken down into "Beer", "Wine", "Spirits" etc and "Cost of Sales" was broken down into "Food", "Beverages", "Condiments" etc.

    I can get the individual items eg "Beer" and "Food" to display correctly, but not the subtotals for "Alcoholic Beverages" or "Cost of Sales". Any thoughts on how this might be done?

    Cheers

Posting Permissions

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