Forum Discussion
Anonymous
9 years agoNot applicable
DAX - IF Format
Hi All, I am trying to do a SUM on column [Total Amount] when column [Promotion_id] is blank AND column [order_order_scr] = 1 My DAX for new column is; NoOfferTotal = IF(AND(FORMAT([order...
- 9 years ago
v-jiascu-msft is right and it's a better solution in case that promition_id is actually "" in some cases.
revised codes:
measure = CALCULATE( SUM('POS Data 1'[Total Amount]), 'POS Data 1'[promotion_id] = BLANK(), 'POS Data 1'[order_order_src] = 1 ) column = IF( AND( 'POS Data 1'[promotion_id] = BLANK(), 'POS Data 1'[order_order_src] = 1 ), 'POS Data 1'[Total Amount] )
Phil_Seamark
9 years agoMicrosoft Employee
Hi Anonymous
Can you please show a snapshot of some of the data so we can see what kind of values are in each column?
That will help reformat the query.
I'm mostly interested in the [order_order_src] column
- Anonymous9 years agoNot applicable
Thanks for the replies.
Both column are whole numbers, see screen shots.