Daily DAX : Day 455 ISNUMERIC

DAX ISNUMERIC / ISNUMBER

Both functions do the same thing — Microsoft calls them aliases.

What they do

Returns TRUE if the value is a number, otherwise FALSE.

Syntax

ISNUMERIC ( <value> )
ISNUMBER  ( <value> )

You can use either name — result is identical.

Simple examples

ISNUMBER( 42 )              → TRUE
ISNUMBER( 3.14 )            → TRUE
ISNUMBER( -500 )            → TRUE
ISNUMBER( "123" )           → FALSE    (it's text)
ISNUMBER( "abc" )           → FALSE
ISNUMBER( BLANK() )         → FALSE
ISNUMBER( TODAY() )         → TRUE     (dates are numeric in DAX)
ISNUMBER( 1/1/2025 )        → TRUE

Most common real-world use cases

  1. Clean dirty imported data (mixed text + numbers)
  2. Safe Number = 
    IF(
        ISNUMBER( Sales[Amount Text] ),
        VALUE( Sales[Amount Text] ),
        BLANK()
    )
  3. Conditional formatting / flags
  4. Is Numeric Flag = 
    IF( ISNUMBER( Data[Column] ), "Number ✓", "Text / Error ✗" )
  5. Avoid errors in calculations
  6. Safe Average = 
    AVERAGEX(
        FILTER( Sales, ISNUMBER( Sales[Price] ) ),
        Sales[Price]
    )
  7. Check before conversion
  8. Converted = 
    IF( 
        ISNUMBER( 'Table'[Qty as text] ), 
        VALUE( 'Table'[Qty as text] ) * [Price], 
        0 
    )
Important:
• Does NOT work in DirectQuery mode for calculated columns / RLS
• Dates / DateTimes return TRUE (they are stored as numbers)
• Currency & Decimal & Whole Number & DateTime → all return TRUE

Comments

Popular posts from this blog

Daily DAX : Day 131 SELECTEDMEASURE

Daily DAX : Day 446 INFO.CSDLMETADATA

Daily DAX : Day 453 ENDOFWEEK