Forum Discussion

AnandRanga's avatar
AnandRanga
Helper III
9 years ago
Solved

Where to write count in this expression ?

this is my sql  query:   select count(Temperature) as TempUP, max([Date]) from Second_18FE34D47A8F$ where Temperature>25 group by [Date] order by [Date]   same expression I want to write in DA...
  • v-yulgu-msft's avatar
    9 years ago

    Hi, AnandRanga

     

    Please try the formula below:

    New Table = SUMMARIZE(
    CALCULATETABLE (
    Second_18FE34D47A8F,
    FILTER ( Second_18FE34D47A8F, Second_18FE34D47A8F[Temperature] > 25 ) ),
    Second_18FE34D47A8F[Date],
    "Count",
    COUNT(Second_18FE34D47A8F[Temperature])
    )

    Thanks,
    Yuliana Gu