Not sure about Oracle, but you should be able to do something like:
from sqlalchemy import func session.query(Employee).filter(Employee.something.in_(func.retrieveList()).all() Not sure about how to get the cursor object. On 04/24/2010 10:38 AM, Mark wrote:
Hi everyone, I'm currently trying to convert an existing Zope web application over to Pylons. My DBA created a whole bunch of stored procedures for the web application that I would really love to use in my Pylons project. Some of the stored procedures takes a "cursor" as an argument. I'm not very DB savvy, so please forgive me if whatever I mentioned above doesn't sound right to you. My Question is: Supposing I have a stored procedure in my Oracle DB called "retrieveList", how do I call that stored procedure to return me a result set in SQLAlchemy?? I know how to do it in the normal ORM way, like: session.query(Employee).filter(Employee.something == something).all() Could you please teach me what to import as well? What are the necessary modules required for calling stored procedures in SQLAlchemy? Thanks a million guys!
-- David Gardner Pipeline Tools Programmer Jim Henson Creature Shop dgard...@creatureshop.com -- You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To post to this group, send email to sqlalch...@googlegroups.com. To unsubscribe from this group, send email to sqlalchemy+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en.