between() on the Column object is probably only in the trunk:
mytable.c.col1.between(3,5)
there *should* be a standalone between() function available in the
release which I think has an underscore (the underscore is optional
in the trunk):
between_(mytable.c.col, 3, 5)
On May 2, 2006, at 12:53 PM, Robin Munn wrote:
http://www.sqlalchemy.org/docs/sqlconstruction.myt says "Supported
column operators so far are ... like(), startswith(), endswith(),
between(), and in()". But between() seems not to work:
In [110]:s = users.select(users.c.age.between(30,39))
----------------------------------------------------------------------
-----
exceptions.AttributeError Traceback (most
recent call last)
/home/rmunn/projects/python/<ipython console>
AttributeError: 'Column' object has no attribute 'between'
This is consistent on SQLite and PostgreSQL. Trying "between_" doesn't
seem to work either.
What's the correct syntax for doing "SELECT * FROM users WHERE age
BETWEEN 30 AND 39"?
--
Robin Munn
[EMAIL PROTECTED]
GPG key
0xD649701-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services,
security?
Get stuff done quickly with pre-integrated technology to make your
job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache
Geronimo
http://sel.as-us.falkag.net/sel?
cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Sqlalchemy-users mailing list
Sqlalchemy-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sqlalchemy-users
4
-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Sqlalchemy-users mailing list
Sqlalchemy-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sqlalchemy-users