Support Questions

Find answers, ask questions, and share your expertise
Announcements
Check out our newest addition to the community, the Cloudera Data Analytics (CDA) group hub.

Beeline equivalent for hive cli -v

New Contributor

I am looking for beeline equivalent for hive cli -v(echo executed SQL to the console).  In beeline --verbose mode is there but it does not echo executed SQL like cli does. It just shows the error and debugging info. Is there any way i can get executed SQL for beeline?

sample queries)

hive -v -e "alter table table1 drop partition(keyword='value');" > test.log  - add SQL to test.log

beeline --verbose -e "alter table table1 drop partition(keyword='value');" > test.log  - does not add SQL to test.log

3 REPLIES 3

Rising Star

@Ganeshk Can you please share hive version used for both cases?

are you using custom logging for beeline in both cases?

New Contributor

@AsimShaikh  version used for hive cli 1.2.1. Version used for beeline 3.1.3. I am using shell script redirect just to log into a log file. hive -v -e "alter table table1 drop partition(keyword='value');" > test.log

Expert Contributor

@Ganeshk Yes, we do not have any flag equivalent to -v in beeline. However, if we are looking for the command itself, you could find it in the line stating "Compiling command" or "Executing command"

Take a Tour of the Community
Don't have an account?
Your experience may be limited. Sign in to explore more.