〜150列のテーブルがあります。各列を見つけたいのcount(distinct(colName))
ですが、実際に各列名を入力せずにそうする方法があるかどうか疑問に思っています。
理想的には使用しますcount(distinct(*))
が、これは機能しません。
他の提案はありますか?
編集:
これが私のテーブルの場合:
id col1 col2 col3 ...
01 10001 west north
02 10001 west south
03 10002 east south
04 10002 west north
05 10001 east south
06 10003 west north
この出力を探しています
count(distinct(id)) count(distinct(col1)) count(distinct(col2)) count(distinct(col3))
6 3 2 2