Forum Discussion
edhans
7 years agoCommunity Champion
Has anyone been able to reliably use Table.ColumnsofType() in Power Query?
I get random success/failures with this function. I have a table called Sales with several columns - number, text, Int64.Type, etc. The following in a new query returns nothing in the list. No er...
freder1ck
7 years agoKudo Kingpin
Interesting. My testing shows that all number types: Number.Type, Int64.Type, Currency.Type, Decimal.Type are treated the same for this function. Number.Type is a kind of generic which includes Int64, Decimal, Currency, etc.
= Table.ColumnsOfType(#"Query", {Int64.Type})
is the same as
= Table.ColumnsOfType(#"Query", {Number.Type})
edhans
7 years agoCommunity Champion
Well, I didn't even know Number.Type was valid. Seems to be identical to "type number" when typing a column though.
And I still cannot get it to work in my example file. type number or Number.Type returns a empty list.
I think this is a poorly documented function, and a buggy one. But I'd love it if someone could jump in with the correct syntax.