You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@superset.apache.org by gi...@git.apache.org on 2017/09/21 09:13:50 UTC
[GitHub] JazzChen commented on issue #2950: jdbc+hive in sqlalchemy URI is not working
JazzChen commented on issue #2950: jdbc+hive in sqlalchemy URI is not working
URL: https://github.com/apache/incubator-superset/issues/2950#issuecomment-331099646
SQLAlchemy URI:
hive://localhost:10000
I solved this problem by follow reference. Hope follow info. could help
https://pypi.python.org/pypi/PyHive
--------------------
from sqlalchemy import *
from sqlalchemy.engine import create_engine
from sqlalchemy.schema import *
# Hive
engine = create_engine('hive://localhost:10000/default')
logs = Table('my_awesome_data', MetaData(bind=engine), autoload=True)
print select([func.count('*')], from_obj=logs).scalar()
--------------------
Requirements
Install using
pip install pyhive[hive] for the Hive interface and
pip install pyhive[presto] for the Presto interface.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services