Questions tagged [pyhive]

107 questions
0
votes
0 answers

Issue while connecting to Hive using Pyhive Library

I have installed all the required libraries (thrift, thrift-sasl, PyHive, sasl) and tried to make connection with hive using PyHive. Also using Python3 Expecting to have a successful connection to hive using PyHive library. I am doing this entire…
Pruthvi
  • 1
  • 1
0
votes
0 answers

Error while compiling statement: FAILED: ParseException line 1:19 cannot recognize input near 'current_date' '(' ')' in expression specification

I tried using pyhive to execute SQL statements: select current_date(); But it made an error just like the title. raise OperationalError(response) pyhive.exc.OperationalError: TExecuteStatementResp(status=TStatus(errorCode=40000,…
0
votes
1 answer

Connecting to hive in an MIT kerberos authenticated cloudera hadoop server from a server without kerberos

I want to connect to the hive service in an MIT kerberos authenticated cloudera hadoop server. I am using a Python script which is hosted on a windows server with no kerberos installed. I am using a conda environment with Python 3.9.7 and Pyhive…
shad0w
  • 3
  • 8
0
votes
0 answers

Unable to connect hive beeline through python

I am not able to connect hive through python/spark in jupyter notebook. I am using version 2.7 of python. Can someone please help? First approach: import commands cmd='beeline -u "jdbc:hive2://...../principal =hive/url;ssl=true" -e '"select * from…
0
votes
0 answers

Pyhive error after upgrading from CDH to CDP private cloud

May I have your help to resolve below error from Pyhive Module. Issue: We have upgraded the Cloudera cluster from CDH version to CDP version. We are using Pyhive python module to get the impala connection from Impala using pyhive…
0
votes
0 answers

Connect to EMR Presto in Python

How do you connect remotely to AWS EMR Presto from Python using pyhive? I am currently using Hue to run queries, but I would like to run queries directly from Pythin and use the results in further computations. I connected to the master node using…
0
votes
1 answer

Pyhive connection on docker container

I am using Apache Kylin on a docker container, the services working normally, but I am having some troubles connecting to Hive using pyhive. I would like to list my databases using "show databases;" in code bellow, but I'm getting this…
0
votes
0 answers

Unable to run a Impala query through Python script when Impala is load balanced

I want to run this simple script: from pyhive import hive import sqlalchemy from impala.dbapi import connect import pandas as pd def conn(): return connect(host='mid.impala.mycompany.com', port=21050, auth_mechanism='GSSAPI', use_ssl=True, …
gianluca
  • 1
  • 3
0
votes
0 answers

thrift.transport.TTransport.TTransportException: Could not connect to any of [port , 10000] PyHive

I am having issues with my python code. When I run my code. It says [2022-02-11 09:58:28,740] ERROR in app: Exception on /process_file [POST] Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/flask/app.py", line 2073,…
Asad Mehmood
  • 292
  • 2
  • 10
  • 20
0
votes
1 answer

pyhive, Cannot initialize Cluster. Please check your configuration

I use pyhive with dolphinscheduler in my program, it works good in develop environment, but it sometimes failed, sometimes succeed in production environment. I do not know why? Example code from pyhive import hive conn = hive.Connection(host="cdh1",…
distinct
  • 29
  • 3
0
votes
1 answer

How to Connect to Hive via pyhive from Windows

I've been racking my brain for the past couple of days attempting to connect to a Hive server with a Python client using pyhive on Windows. I'm new to Hive (pyhive too for that matter), but am a reasonably experienced Python dev. Invariably I get…
Dan
  • 114
  • 2
  • 9
0
votes
1 answer

Is there any way to create a database on Hive using Python?

I want to automate the whole process to test a scenario where I would like to create a database, perform an operation and then delete the database. Is there any way to do it using Python 3. I tried with PyHive, but it requires the database name to…
0
votes
1 answer

PyHive unable to fetch logs from HiveServer2 when running in async mode

I am running into a strange issue with PyHive running a Hive query in async mode. Internally, PyHive uses Thrift client to execute the query and to fetch logs (along with execution status). I am unable to fetch the logs of Hive query (map/reduce…
satish
  • 246
  • 2
  • 9
0
votes
1 answer

Unable to install sasl on MAC

In order to connect to Hive data warehouse from python. Using pyhive requires sasl - ModuleNotFoundError: No module named 'sasl' Installing sasl fails with errors below Python 3.9.4 installed gcc, libsasl2 MACOS Mojave v 10.14 pip3 install sasl …
horse
  • 61
  • 5
0
votes
1 answer

How to access Hive created in EMR cluster from Python

My hive table resides in EMR cluster. I have created SSH tunnel : ssh -L 8888:localhost:8888 -i atlas-emr-xx.pem hadoop@ec2-aa-bbb-ccc-ddd.us-west-2.compute.amazonaws.com I am able to create and access the hive tables thru HUE from…
usr_lal123
  • 650
  • 12
  • 28