2

I'm trying to compare the column count of two tables, one in SSMS and one in DAX Studio, but I've never worked with DAX or Dax Studio before.

In SSMS, I ran SELECT COUNT(*) FROM MyTable to see the rowcount.

In DAX Studio, I ran COUNTROWS(MyTable) but it produced this error:

The syntax for '<pii>COUNTROWS</pii>' is incorrect.

I know there's probably something I need to add to make a valid query but can't find it. How can I query the row number of a table?

Gangula
  • 5,193
  • 4
  • 30
  • 59
half of a glazier
  • 1,864
  • 2
  • 15
  • 45

1 Answers1

2

Youre using dax studio. it can only return table expressions So you need to create a table in your dax expression.

like this :

EVALUATE
ROW("RowCount", COUNTROWS(MyTable))