counta
10 TopicsHow to apply Countif based on measure value
Hi, I have currently 2 tables as follows Table 1 (Multiple Side filter apply to get the measure value) Year Resource Measure Value 2024 A 1 2024 B 2 2024 C 0 2024 D 0 2024 E 3 2024 F 2 Table 2 (Same Multiple Side will be apply to get the measure (Countif) value) Value (Static Value from 0 - 10m Measure value in table 1 will only be 0 - 10) Measure (Countif) 0 2 1 1 2 2 3 1 How can I get the measure (Countif) based on the Resource count. ThanksSolved574Views0likes2CommentsAverage Monthly Count dynamically with Start Dates
I'm trying to create a Dax Calculation where it gives me the average number of dates entered monthly for the company or for specific employees selected in a slicer. If an employee is selected in the slicer, it must take into account the employees start date, so if a time range is selected before the employee started working, then it will dynamically calculate based on the number of months the employee has been employed. For example, an employee starts work on December 1st 2022 and enters 2 dates in December and 4 dates in January. The company as a whole entered 6 dates in November, 9 dates in December and 12 dates in January. If the enduser selects November through January in the slicer, the company average will be 9 dates entered per month. Then if the enduser selects the employee, it will show 3 dates entered per month because it's not including November which is the month before the employee started. If in February the company and employee both have 0 dates entered, the company calculation would be (6+9+12+0)/4 = 6.75 and the employee calculation would be (2+4+0)/3 = 2. I was able to come up with a calculation that works for last year when an employee is selected, but when an employee is not selected, it still uses the max employee start date for the company. This is also for the entire year and does not work when selecting months in the slicer. Leads Assigned Weekly Average Last Year = IF(YEAR(MAX('SDRs (Accounts)'[Start Date]))=YEAR(TODAY())-1,DIVIDE([Leads Assigned],52-WEEKNUM(MAX('SDRs (Accounts)'[Start Date]))),DIVIDE([Leads Assigned],52)) Leads Assigned =CountA(Lead Date)518Views1like1CommentProblems with using COUNTA with multiple choice cells from a Microsoft List
Good afternoon. I am having some issues using COUNTA when counting populated column cells in data view that contains text from a Microsoft List that uses a choice selection (Yes, No, or left blank) in the column cells. It appears that the COUNTA syntax is reading that the cells in the columns have text in them even thought they are blank. I beleive it may be detecting that the column cells have a choice fuction in them from the Microsoft List, even when they do not have any text in them currently. I can see the blank cells in the data view, but they are still being counted as populated in the report view. The COUNTA syntax is working correctly for my column cells that use a date in them. Below is the COUNTA syntax I am using. Any insight on why this is occuring and how to work around this issue would be greatly appreciated. Thank you for your help. Complete = COUNTA('ALL'[AS9100]) + COUNTA('ALL'[FGOPS]) + COUNTA('ALL'[FOD Control Calculated]) + COUNTA('ALL'[Tool Control Calculated]) + COUNTA('ALL'[GSE]) + COUNTA('ALL'[Tow Operations]) + COUNTA('ALL'[Jacking Operations Calculated]) + COUNTA('ALL'[Mooring/Hangaring/Security]) + COUNTA('ALL'[Tire/Wheel]) + COUNTA('ALL'[Battery]) + COUNTA('ALL'[Corrosion]) + COUNTA('ALL'[HAZMAT]) + COUNTA('ALL'[Safe-for-Maintenance]) + COUNTA('ALL'[Egress Calculated]) + COUNTA('ALL'[W&B]) + COUNTA('ALL'[Technical Data (orders, manuals, IETMs)]) + COUNTA('ALL'[Aircraft Records Management]) + COUNTA('ALL'[CADS Calculated]) Best regards, Brian936Views0likes3CommentsCOUNTA inside CALCULATE inside IFBLANKS inside IF :)
Hi All, I have the following forumla which gives a count of 'Cancelled' demands in an inventory management system. I want to be able to turn it into an IF statement, that if the result is blank, show as a 0. The main reason is to get it to show 0 in a card visual. What I have so far is below. Count of Cancelled = CALCULATE( COUNTA('Demand Satisfaction Report'[Comments]), 'Demand Satisfaction Report'[Comments] IN { "Cancelled" } )Solved649Views0likes1CommentAssistance with Dax formula for occurrence of character in column
Hi folks, Is there an efficient Dax formula I can use to count the number of occurences of a particular special character in a column based on conditions? The column looks something like this: Column A Bill Murray John Doe; Joe Biden; Bill Gates Mark Twain; Paul Bunyan; Jack Black Stevie Wonder; Erica Karros Due to the presence of the occasional blank cell, I need ensure that only cells with characters in them are counted, which led me to COUNTA() (not every cell has as a delimiter next to a user's name (e.g. if only one user is listed)). The logic I was considering involved firstly testing to ensure the cell wasn't blank, and then I needed to start counting the number of delimiters in each row with a base count of 1 (again to account for cells with text in them, but do not contain the delimiter in question). Hope that makes sense and appreciate the help, particularly if there's an easier way to do this. I didn't want to unpivot the column and count that way in Power Quert since the table is already too big. Best, pbrenneiseSolved949Views0likes2Commentscounting values with conditions using DAX
I feel like this is a very simple questions, but can't seem to get it to work. I'm trying to do a countif in essence. I basically want to summarize the number of machines needed to make certain products. Product No of Machines Biscotti 3 Cream Donut 7 Caramel 3 Chocolate cookies 7 Double Chocolate 3 Chocolate Donut 3 Custard Donut 7 Deluxe Cookies 3 I can do that using: No of Machines = COUNTROWS('Target Speeds' ) However I want to isolate the measure outside of the views context, so I can use it in a DAX formula. So if I bring machine into the visual I still get the same results. Product Machine No of Machines Biscotti Jam Machine 3 Biscotti Pressing Machine 3 Biscotti Sprinkling Machine 3 Cream Donut Boxing Machine 7 Cream Donut Filling Machine 7 Cream Donut Forming Machine 7 Cream Donut Heating Machine 7 Cream Donut Mixing Machine 7 Cream Donut Topping Machine 7 Cream Donut Packaging Heat Machine 7 Caramel Jam Machine 3 Caramel Pressing Machine 3 Caramel Sprinkling Machine 3 Chocolate cookies Boxing Machine 7 Chocolate cookies Filling Machine 7 Chocolate cookies Forming Machine 7 Chocolate cookies Heating Machine 7 Chocolate cookies Mixing Machine 7 Chocolate cookies Topping Machine 7 Chocolate cookies Packaging Heat Machine 7 Double Chocolate Jam Machine 3 Double Chocolate Pressing Machine 3 Double Chocolate Sprinkling Machine 3 Chocolate Donut Jam Machine 3 Chocolate Donut Pressing Machine 3 Chocolate Donut Sprinkling Machine 3 Custard Donut Boxing Machine 7 Custard Donut Filling Machine 7 Custard Donut Forming Machine 7 Custard Donut Heating Machine 7 Custard Donut Mixing Machine 7 Custard Donut Topping Machine 7 Custard Donut Packaging Heat Machine 7 Deluxe Cookies Jam Machine 3 Deluxe Cookies Pressing Machine 3 Deluxe Cookies Sprinkling Machine 3 Any advice?Solved745Views0likes2CommentsHi, Could you please explain me me how to do a count of column items in particular date period ?
Hi, Please explain me how to do the count of coloumn item in a particlar time period ? and last three days ? I have a sales data with particlar sales type " Direct", "Inderect", etc. I want to count this based on the time period and MTD. 1) Do I need a sperate Clander table to use the time intelligence functions ? 2) What is the DAX for this 3) Do I need key tables ? 4) What are the parameters I need to choose for a matrix visulization ? 5) How to automate this report ? I want send this automatically on daily once in a particlar time.Solved2.2KViews0likes5CommentsCreating Measures for distinct count between 2 custom dates
I have a dataset of leads with unique IDs and lead dates for the past 2 years. However, the years are not based on the calendar year, but a custom time frame 8/1 - 7/31. I also created a date table. I would like to create measures that do the following - Prior Year leads - distinct count of IDs for lead date between 8/1/19 - 7/31/2020 Current Year leads - distinct count of IDs for lead date between 8/1/20 - 7/31/2021 Prior Year Leads to date - count of prior year leads up to current date I was able to do this with the data separated into 2 queries using DAX below, but was unsure how to accomplish it with mixed data set. Total CY Leads = COUNTA(CY_Leads[CONTACTID]) Total PY Leads = COUNTA(PY_Leads[CONTACTID]) Thank you616Views0likes2CommentsCOUNTA and SUM for different periods
Hi All! It's me again.. lol This time I'm trying to build a report to show how many different payment terms we have by supplier at each period. My database looks like this: As of WeekNum Supplier Payment term 10.aug.20 33 A 30 days 10.aug.20 33 C 60 days 10.aug.20 33 Y 30 days 10.aug.20 33 A 90 days 10.aug.20 33 Y 75 days 10.aug.20 33 Z 120 days 10.aug.20 33 Y 45 days 17.aug.20 34 A 60 days 17.aug.20 34 B 30 days 17.aug.20 34 T 90 days 17.aug.20 34 Y 75 days 17.aug.20 34 U 120 days 17.aug.20 34 B 45 days 17.aug.20 34 Y 60 days 17.aug.20 34 U 30 days The output i'm looking for is: Number of payment terms Number of suppliers Week 33 1 2 2 1 3 1 Week 34 1 2 2 3 I've been trying to do that through a New Column and Measure.. but failed on both! Absolutely no clue about this one..Can you help me with this one additional question?? 😁 Thanks again for the support!Solved929Views0likes3CommentsCalculating a value in a cell except for Blanks and N/A
Hi, I am trying to calculate a Measure in power BI that returns me a count if a value is present in a cell, except for N/A and blanks, similar to the Total Fruit & Vegetables column below: Fruit Vegetables Total Fruit & Vegetables Apple N/A 1 Orange Cucumber 2 Celery 1 Does anyone know what is the line of code for this in DAX Power BI? Thanks in advanceSolved1.8KViews0likes2Comments