[sqlalchemy] Get value for each instance

2008-12-24 Thread Kless
How to get the value for a column for each instance --from a descriptor--? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups sqlalchemy group. To post to this group, send email to sqlalchemy@googlegroups.com To

[sqlalchemy] Re: Get value for each instance

2008-12-24 Thread Kless
Well, at the end I found a post that could be the solution: http://beachcoder.wordpress.com/2007/05/02/adding-event-callbacks-to-sqlalchemyelixir-classes/ On 24 dic, 15:48, Kless jonas@googlemail.com wrote: How to get the value for a column for each instance --from a descriptor--?

[sqlalchemy] Empty ResultProxy, but SQL statement yields results

2008-12-24 Thread Philip
I am having a problem that I am not able to figure out. Maybe someone else can see what I am doing wrong. I am building a query using the SQL expression language. Then printing the SQL statement and counting the resulting records. When I run the generated SQL statement in the command-line MySQL

[sqlalchemy] Re: Empty ResultProxy, but SQL statement yields results

2008-12-24 Thread Michael Trier
Record_count is never set. Michael On Dec 23, 2008, at 3:27 PM, Philip philwr...@gmail.com wrote: I am having a problem that I am not able to figure out. Maybe someone else can see what I am doing wrong. I am building a query using the SQL expression language. Then printing the SQL

[sqlalchemy] declerative base and relation

2008-12-24 Thread vctr...@gmail.com
Hi, I tried the following example (from the documentation): class User(Base): __tablename__ = 'users' id = Column(Integer, primary_key=True) name = Column(String(50)) addresses = relation(Address, backref=user) class Address(Base): __tablename__ = 'addresses' id =

[sqlalchemy] Transparent Web Service with SqlAlchmey?

2008-12-24 Thread Arthur Pemberton
My googling hasn't yet been fruitful Are there any existing solutions which would essentially allow me to build a web service which can be consumed by a 'client side' python app which would serve SqlAlchmey models transparently such that data would be be retrieved from the web service end,

[sqlalchemy] Re: declerative base and relation

2008-12-24 Thread Michael Bayer
Here's some additional example: from sqlalchemy import * from sqlalchemy.orm import * from sqlalchemy.ext.declarative import declarative_base engine = create_engine('sqlite://', echo=True) Base = declarative_base() class User(Base): __tablename__ = 'users' id = Column(Integer,