yup, use "deferred" loading:

http://www.sqlalchemy.org/docs/ adv_datamapping.myt#adv_datamapping_deferred

On May 19, 2006, at 11:13 AM, Dennis Muhlestein wrote:

I have a table that has a couple informational columns and then a binary (bytea in postgresql) column. I usually don't want to select the binary data unless I need it. Is there a way to lazy load columns on a Mapped class? Because of my special case with that one class, I usually just do a select ( [columns I want] .... ) and manually access the data but it would be nice to use the mapper and then just have the binary data loaded if I access that column.

I could create a relation and put the binary data in another table and lazy load that but then I'd have to do a join every time I did want the data so I guess I chose the lesser of two evils.

-Dennis



-------------------------------------------------------
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

Reply via email to