Problems with "Subselect" in SQL statment
Hello List, I have a problem using ZSQL Methods. If I do something like this: select * from person where id != (Select userid from projektmitglieder where projektid='20'); Zope gives me an error ! Error Type: ProgrammingError Error Value: ERROR: More than one tuple returned by a subselect used as an expression. select * from person where id != (Select userid from projektmitglieder where projektid='20'); But if I try this on the test chapter of my DB adapter is works and the ZSQL Method also works well if I call it manually !! Does someone knows a solution Thanks in advance Florian Schuler
On 05.11.2001 - 13:17 Florian Schuler wrote:
Hello List,
I have a problem using ZSQL Methods. If I do something like this:
select * from person where id != (Select userid from projektmitglieder where projektid='20');
Zope gives me an error !
You should probably use : select * from person where id not in (select userid ... ); and this even if your subrequest is known to always retrieve only one row !! Thierry
participants (2)
-
Florian Schuler -
Thierry FLORAC