Re: [sqlalchemy] dynamically mapped tables with ORM

2013-03-04 Thread Michael Bayer
Have you looked at SQLSoup ? This library already does exactly what you're looking for. https://sqlsoup.readthedocs.org/en/latest/ For the most part, I have this working. However, the example in the gist shows that: len(g.cpgIslandExt.all()) != g.cpgIslandExt.count() What does your

Re: [sqlalchemy] dynamically mapped tables with ORM

2013-03-04 Thread brent
On Monday, 4 March 2013 11:57:01 UTC-7, Michael Bayer wrote: Have you looked at SQLSoup ? This library already does exactly what you're looking for. https://sqlsoup.readthedocs.org/en/latest/ wow! yeah that does do what I'm looking for. However, I'm mapping to tables that do not have

Re: [sqlalchemy] dynamically mapped tables with ORM

2013-03-04 Thread brent
On Monday, 4 March 2013 12:16:49 UTC-7, brent wrote: On Monday, 4 March 2013 11:57:01 UTC-7, Michael Bayer wrote: Have you looked at SQLSoup ? This library already does exactly what you're looking for. https://sqlsoup.readthedocs.org/en/latest/ wow! yeah that does do what I'm

Re: [sqlalchemy] dynamically mapped tables with ORM

2013-03-04 Thread Michael Bayer
you can control the whole thing using map_to(): https://sqlsoup.readthedocs.org/en/latest/api.html#sqlsoup.SQLSoup.map_to , however that would mean you'd need to build the Table reflection outside of calling that in any case. Another approach might be just to subclass the SQLSoup object and

Re: [sqlalchemy] dynamically mapped tables with ORM

2013-03-04 Thread Michael Bayer
On Mar 4, 2013, at 2:21 PM, brent bpede...@gmail.com wrote: I found this in the archives: https://groups.google.com/forum/?fromgroups=#!topic/sqlalchemy/EUyt8HUzJC8 are things still the same? Sort of, I moved SQLSoup out to its own project some time back, and its really a pretty simple

Re: [sqlalchemy] dynamically mapped tables with ORM

2013-03-04 Thread brent
On Monday, 4 March 2013 12:33:33 UTC-7, Michael Bayer wrote: On Mar 4, 2013, at 2:21 PM, brent bped...@gmail.com javascript: wrote: I found this in the archives: https://groups.google.com/forum/?fromgroups=#!topic/sqlalchemy/EUyt8HUzJC8 are things still the same? Sort of, I moved