Michael Chambliss wrote:
Michael Bayer wrote:
On Jan 26, 2010, at 7:48 PM, Michael Chambliss wrote:
Presently, I'm trying to determine the best way to map a class against an
arbitrary select where the select is constructed from raw SQL. Based on this,
it's possible using the expression
Michael Chambliss wrote:
Hey Michael - thanks for the patient and helpful response. I played
around with the from_statement() approach earlier today, but what I was
able to derive seemed to follow the standard model of define table,
define class, map table to class, execute query. That
-Original Message-
From: sqlalchemy@googlegroups.com
[mailto:sqlalch...@googlegroups.com] On Behalf Of Michael Bayer
Sent: 27 January 2010 16:31
To: sqlalchemy@googlegroups.com
Subject: Re: [sqlalchemy] Map to Arbitrary Select Using Raw SQL
Michael Chambliss wrote:
Hey Michael
Michael Chambliss wrote:
vehicle_query =
select
v.vehicle_id as vehicle_id,
v.name as vehicle_name,
v.description as vehicle_description,
vt.name as vehicle_type,
vs.name as vehicle_status,
v.modify_dttm as vehicle_modify_dttm
King Simon-NFHD78 wrote:
You'll have to give it a table name, which will have the effect of
defining a Table object even though no such table exists in the
database, but I don't think this matters. Then you could use the query
that Mike suggested to actually retrieve rows
Thanks, Simon - I ended
Hello,
I'm new to SQLAlchemy (and really Python in general) and admittedly I'm
probably not following the best process for learning it. Ultimately,
I'd prefer to deal with raw SQL as opposed to working through the
expression building methods despite the benefits of the framework I
leave on
On Jan 26, 2010, at 7:48 PM, Michael Chambliss wrote:
Hello,
I'm new to SQLAlchemy (and really Python in general) and admittedly I'm
probably not following the best process for learning it. Ultimately, I'd
prefer to deal with raw SQL as opposed to working through the expression
Michael Bayer wrote:
On Jan 26, 2010, at 7:48 PM, Michael Chambliss wrote:
Presently, I'm trying to determine the best way to map a class against an
arbitrary select where the select is constructed from raw SQL. Based on this,
it's possible using the expression builders: