I wouldn't mind having a look at a complete test case (i.e., one that
includes table definitions)

On 10/19/06, Sandro Dentella <[EMAIL PROTECTED]> wrote:
> hi all,
>
>    eng = sa.create_engine('sqlite:///cinemino.db')
>    adm_log = sa.Table('django_admin_log', eng , autoload=True)
>    fk = adm_log.c['user_id'].foreign_key
>    print "FK", fk
>    print fk.column.table.name
>
> prints ok with SA rel 1685:
>
>   FK ForeignKey('"auth_user".id')
>   "auth_user"
>
> but raises this error now:
>
> FK ForeignKey('"auth_user".id')
> Traceback (most recent call last):
>   File "dj_test.py", line 10, in ?
>     print fk.column.table.name
>   File "/usr/lib/python2.4/site-packages/sqlalchemy/schema.py", line 569, in 
> <lambda>
>     column = property(lambda s: s._init_column())
>   File "/usr/lib/python2.4/site-packages/sqlalchemy/schema.py", line 547, in 
> _init_column
>     raise exceptions.ArgumentError("Invalid foreign key column specification: 
> " + self._colspec)
> sqlalchemy.exceptions.ArgumentError: Invalid foreign key column 
> specification: "auth_user".id
>
>
> Any hints?
> TIA
>
> sandro
> *:-)
>
> --
> Sandro Dentella  *:-)
> http://www.tksql.org                    TkSQL Home page - My GPL work
>
> -------------------------------------------------------------------------
> 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
>


-- 
Jonathan Ellis
http://spyced.blogspot.com

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