How to get the impala query output log into a variable using unix shell script?
问题 I'm creating unix shell script to execute the impala query. I need to get the output log of impala query. For example I tried the below. output_log = echo $(impala-shell -i $node -q "select name from impaladb.impalatbl" -o output_file) Output: +--------+ | name | +--------+ | tom | | mike | +--------+ Fetched 2 row(s) in 0.83s Here I'm getting the two name output in both output_file and output_log. But I need the "Fetched 2 row(s) in 0.83s" log in output_log variable. How can I get it? 回答1: I