Hi All,
I'm working on making PyHive compatible with SQLAlchemy
1.2.8: https://github.com/Fokko/PyHive/tree/fd-fix-tests
Now I run into some problems which is I can't figure out. Hopefully there
is anyone who has more experience with this than me. The dbapi_type_map has
been deprecated in 1.2 and now I'm unable to parse the types with raw
queries. What does work:
tbl = Table('one_row_complex', MetaData(bind=engine), autoload=True)
rows = tbl.select().execute().fetchone()
self.assertEqual(list(rows[0]), _ONE_ROW_COMPLEX_CONTENTS)
What doesn't work:
row = connection.execute('SELECT * FROM one_row_complex').fetchone()
self.assertEqual(row, _ONE_ROW_COMPLEX_CONTENTS)
I found out that the following routine isn't invoked when running the raw
sql:
https://github.com/Fokko/PyHive/blob/master/pyhive/sqlalchemy_hive.py#L229-L258
Does anyone know how to convert the datetime and the decimal when running
the raw SQL? I when through all the documentation and tried a lot (as you
might see in the pull-request), but I couldn't get it to work.
Please let me know,
Kind regards, Fokko
--
SQLAlchemy -
The Python SQL Toolkit and Object Relational Mapper
http://www.sqlalchemy.org/
To post example code, please provide an MCVE: Minimal, Complete, and Verifiable
Example. See http://stackoverflow.com/help/mcve for a full description.
---
You received this message because you are subscribed to the Google Groups
"sqlalchemy" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/sqlalchemy.
For more options, visit https://groups.google.com/d/optout.