How to view the value of a hive variable? How to view the value of a hive variable? sql sql

How to view the value of a hive variable?


Found my answer. The answer is simply:"Set a;"Stupid syntax IMO, but thats the way it is.


Another way to view the value of a variable is via the hiveconf variable

hive> select ${hiveconf.a};

where a is the variable name

To see the values of all the variables, simply type

set -v


The bellow will set the value of zzz

hive> set zzz=5;

To see what value in zzz use the bellow command

hive> set zzz;zzz=5