Hi...

I'm having some trouble with creating a select statement with a where
clause that uses a literal value ... in the process of debugging i've
narrowed it down to the way the interpreter treats the == operator
when bound to an sqlite database (this problem goes away when I use
oracle). Basically, if I print the statement:

print bondData.c.NORTHINFO_RATING == "AAA"

I get:

"BOND_DATA"."NORTHINFO_RATING" = ?

which, when used as a where clause in a query, produces no records
whereas when i use oracle via cx_oracle, the statement

print bondData.c.northinfo_rating == "AAA"

gives me:

"BOND_DATA".northinfo_rating = :northinfo_rating_1

which produces a query that returns a data set from the table
"BOND_DATA" where values of the column northinfo_rating = "AAA"...
This clearly is the desired result...

Any tips as to what I'm doing wrong wrong in the sqlite case?

BTW... the capitalization of the column names is different for the two
databases because I've realized by trial and error that oracle column
names should be in lower case whereas sqlite column names should be in
whatever letter-case they were specified in the DB...

Any help would be greatly appreciated.

d.

-- 
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sqlalchemy?hl=en.

Reply via email to