Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Fastconnect problem for sqlline.py for connecting to Apache Phoenix

Fastconnect problem for sqlline.py for connecting to Apache Phoenix

Explorer

I want to give sqlline command to connect to Apache Phoenix.

in the file fastconnect parameter is set to false... And I do not want to change it.

However, for adhoc select query operations, I want to make it true while connecting...

How can I do that?

Or, do I have to compulsorily change the sqlline.py file?

3 REPLIES 3

Re: Fastconnect problem for sqlline.py for connecting to Apache Phoenix

Master Guru
Given that its currently hardcoded into Phoenix's sqlline.py file, your
only resort would be to maintain a duplicate modified copy of the
sqlline.py (or use the evaluated java sqlline command directly) where you
have the option set differently.

Re: Fastconnect problem for sqlline.py for connecting to Apache Phoenix

Explorer

If I make another copy of sqlline.py file , lets say sqlline1.py and change value of fastconnect as true in it... And call it for those adhoc operations, can it work?

 

And Do I need any other configurations changes?

 

 

Also,

 

Can you please explain, how can I use the evaluated java sqlline command directly?

Highlighted

Re: Fastconnect problem for sqlline.py for connecting to Apache Phoenix

Master Guru
Yes a duplicate will work as long as you're calling it in the same way.

As to using the evaluated java command, you can for example print the
command out from sqlline.py to see the final built command and then use
that directly (outside of python). This may not be necessary to do though,
since duplicating the sqlline.py is an easier way to the same thing. I
suggested this so you have fuller control on the SQLLine directly, if you
need that.