+ Reply to Thread
Results 1 to 1 of 1

Replacement for this COUNTIFS formula using Power Query?

  1. #1
    Forum Contributor
    Join Date
    04-14-2008
    Location
    Fort Collins, Co
    MS-Off Ver
    2016
    Posts
    107

    Replacement for this COUNTIFS formula using Power Query?

    SOLVED. Here's what I did: I made a new query that filtered out blanks on column A and only show items with "1" in column V. Then I grouped by columns C, L, M & U and made a count of distinct rows. I then merged this query back to my main one.

    I have a countifs formula that looks like this, which repeats for each row in a column and the criteria is always the current row item.

    =IF(A2="","",COUNTIFS($C$2:$C$1568,C2,$L$2:$L$1568,L2,$M$2:$M$1568,M2,$U$2:$U$1568,U2,$V$2:$V$1568,1))

    Translation: If A2 is blank, leave the formula cell blank. Otherwise, count any items that match the current cell values in columns C, L, M and U but only if V = 1.

    How can I do this in Power Query? I'm aware of the grouping function, but I can't seem to figure out how to implement. My brain is not working well today!

    Thank you
    Last edited by 4am; 03-26-2018 at 04:54 PM.
    Is That Your Spreadsheet Or Did Your Database Just Throw Up?


+ 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. error in power query & power pivot
    By Baldev Kumar in forum Excel Charting & Pivots
    Replies: 8
    Last Post: 01-03-2018, 01:34 AM
  2. Data transformation using Formula or Power Query
    By chullan88 in forum Excel Formulas & Functions
    Replies: 14
    Last Post: 11-18-2017, 09:59 AM
  3. Power query formula
    By orhanceliloglu in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-19-2017, 11:28 AM
  4. Power Query Formula/Syntax
    By mielkew27 in forum Excel General
    Replies: 2
    Last Post: 04-09-2017, 11:44 PM
  5. How do I get my formula to work in a power query
    By Justair07 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 09-22-2016, 10:34 AM
  6. [SOLVED] Formula Creation with Power Query
    By Bhalbert in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-05-2016, 01:11 PM
  7. Replacement for COUNTIFS
    By di22y in forum Excel General
    Replies: 10
    Last Post: 06-04-2009, 04:12 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