Re: [SQLObject] how to use sqlmeta.idName?
SQLObject is a Python ORM.
Brought to you by:
ianbicking,
phd
From: <jpa...@gm...> - 2005-07-18 11:09:34
|
And the traceback: Traceback (most recent call last): File "D:/projetos/pontoa2-py/pessoa.py", line 67, in ? for estado in estados: File "c:\Python24\Lib\site-packages\sqlobject\sresults.py", line 147, in __iter__ return conn.iterSelect(self) File "c:\Python24\Lib\site-packages\sqlobject\dbconnection.py", line 359, in iterSelect select, keepConnection=3DFalse) File "c:\Python24\Lib\site-packages\sqlobject\dbconnection.py", line 680, in __init__ self.dbconn._executeRetry(self.rawconn, self.cursor, self.query) File "c:\Python24\Lib\site-packages\sqlobject\dbconnection.py", line 293, in _executeRetry return cursor.execute(query) psycopg.ProgrammingError: ERROR: column estado.id does not exist SELECT estado.id, estado.uf, estado.nome FROM estado WHERE 1 =3D 1 -- JP On 7/18/05, Jo=E3o Paulo Fernandes Farias <jpa...@gm...> wrote: > Sorry! >=20 > I'm on windows XP SP 2 with python 2.4.1 and SQLObject from SVN > (revision from two days ago). I'm using postgresql and psycopg. >=20 > -- > JP >=20 > On 7/18/05, Oleg Broytmann <ph...@ma...> wrote: > > On Sat, Jul 16, 2005 at 01:42:52PM -0300, Jo?o Paulo Fernandes Farias w= rote: > > > class Test(SQLObject): > > > connection =3D _con # connection string > > > sqlmeta.idName =3D 'id_test' > > > test =3D StringCol() > > > > > > test =3D Test.select() > > > > > > This gives me an error because it can't find test.id column.. > > > > http://www.catb.org/~esr/faqs/smart-questions.html#beprecise > > > > OS? DB? Driver? SQLObject's version? Traceback? > > > > Oleg. > > -- > > Oleg Broytmann http://phd.pp.ru/ phd@phd.pp.= ru > > Programmers don't die, they just GOSUB without RETURN. > > > |