Here is another useful link that got me started, see the syntax at the end.
https://pydigger.com/pypi/pyPhoenix <https://pydigger.com/pypi/pyPhoenix>

example::

    import sqlalchemy

    db = sqlalchemy.create_engine('phoenix://localhost:8765/')
    conn = db.connect()



> On Sep 14, 2017, at 5:07 PM, Todd Faucheux <[email protected]> wrote:
> 
> Greetings.
> 
> Curious if anyone has any luck or knows the steps to add Apache Phoenix to 
> Superset as a SQL Alchemy datasource.
> So far I have tried installation of “pyPhoenix" Driver source obtained via 
> https://github.com/Pirionfr/pyPhoenix <https://github.com/Pirionfr/pyPhoenix>
> 
> I can connect outside of superset using python sample code provided by that 
> driver
>  
> I installed the driver into superset docker image in /opt/pyPhoenix and ran 
> “python setup.py install” and the driver dependencies appeared to load fine.
> However if I try to add a new URI in the Datasource page of superset of the 
> form(s):
> 
> phoenix://<query_server_host>:8765/
> pyphoenix://<query_server_host>:8765/
> 
> Both returns an error, stating that it does not know the phoenix dialect.
> Can't load plugin: sqlalchemy.dialects:phoenix
> Can't load plugin: sqlalchemy.dialects:pyphoenix
> 
> I assume the dialect is just phoenix, but I tried pyPhoenix as well.
> 
> Not sure if there are any config files, or other places that I need reference 
> the driver/dialect.
> I did not see any mention of that at: 
> https://superset.incubator.apache.org/installation.html#database-dependencies 
> <https://superset.incubator.apache.org/installation.html#database-dependencies>
> 
> Any ideas or experience with setting up other drivers is appreciated,
> Information on Apache Phoenix:  https://phoenix.apache.org/ 
> <https://phoenix.apache.org/>
> 
> Thanks,
> 
> Todd

Reply via email to