Forum Discussion
wooand
Helper II
8 years agoUsing FIRSTNONBLANK unsuccessfully.
I have data in three columns in table 'Results'. The columns are: A: Deal Reference B: Deal Time C: Deal Rate All cells contain numbers, no text. I need to identify the very first De...
- 8 years ago
HI wooand
Try this formula
Formula = VAR FirstNonBlankTradeStartTime = CALCULATE ( FIRSTNONBLANK ( ALL ( Results[Trade Start Time] ), TRUE () ) ) RETURN CALCULATE ( FIRSTNONBLANK ( Results[Dealt Rate], 1 ), FILTER ( ALL ( Results ), Results[Trade Start Time] = FirstNonBlankTradeStartTime ) )
Greg_Deckler
Community Champion
8 years agoCan you post the DAX for your formula? And could you post some sample data? Are you looking for the firstnonblank for each Deal Reference?
- wooand8 years ago
Helper II
Sure, here's a snip of the Excel data file as it stands:
It carries on in the same vein for several thousand lines.
By using = CALCULATE(FIRSTNONBLANK(Results[Dealt Rate], TRUE()) I get a value, but I want the first one in terms of the Trade Start Time. I'm concerned that there may be a millisecond issue here to boot, but anyway, any help most welcome.
- Zubair_Muhammad8 years ago
Community Champion
- wooand8 years ago
Helper II
No, in this example I would want 1.1726 at the first Trade Time (it's ordered by Trade Time), but for some reason I'm getting some other rate from elsewhere in the data series.