[Zope-DB] PsycoPG adaptor problem?

VanL vlindberg@verio.net
Mon, 11 Nov 2002 11:49:15 -0700


Hello,

I have what appears to be a legal SQL query that gives me a valueerror 
when I try to run it from a ZSQL method.

SELECT * FROM account A,
customer C,
legacy L,
target T,
WHERE C.id = A.cid
AND LA.id = A.lid
AND TA.id = A.tid
AND A.name like <dtml-sqlvar name type="string">;

Running this from psql gives no error. Running this from the ZSQL Method 
gives:

*Error, /exceptions.ValueError/:* Duplicate column name, id

I know that I have a column named 'id' in each table, but to say that I 
can't return * from a join across them because of that doesn't make 
sense.  Has anyone worked around this somehow?

I am using Zope 2.60, (Z)PsycoPG 1.0.13.

VanL

------------------------------------------------------------------------