Re: Help with "missing FROM clause" needed - Mailing list pgsql-sql

From Thomas Beutin
Subject Re: Help with "missing FROM clause" needed
Date
Msg-id 440C46EA.4070504@laokoon.IN-Berlin.DE
Whole thread Raw
In response to Re: Help with "missing FROM clause" needed  (Richard Huxton <dev@archonet.com>)
Responses Re: Help with "missing FROM clause" needed
List pgsql-sql
Richard Huxton wrote:
> Thomas Beutin wrote:
> 
>> Hi,
>>
>> to be compatible with the postgres standard syntax in 8.1.x i need 
>> some help for rewriting my "delete" statements ("select" is not a 
>> problem). I use the following statement:
>>
>> DELETE FROM partner_zu
>> WHERE partner_zu.pa_id = partner.id
>> AND partner_zu.m_id = '25'
>> AND partner.open = 'm'
>> AND partner.a_id = partner_zu.a_id
>> AND partner_zu.a_id = '104335887112347';
> 
> 
> DELETE FROM partner_zu
> WHERE
>   partner_zu.m_id = '25'
>   ...etc...
>   AND partner_zu.pa_id IN (
>     SELECT id FROM partner WHERE open='m' AND a_id='104335887112347'
>   )
> 
> Does that work for you?
What should i do with the "AND partner.a_id = partner_zu.a_id" ? Without 
this it would be working fine.

Greetings,
-tb
-- 
Windows: "Where do you want to go today?"
Linux: "Where do you want to go tomorrow?"
FreeBSD: "Are you guys coming, or what?"


pgsql-sql by date:

Previous
From: Richard Huxton
Date:
Subject: Re: Help with "missing FROM clause" needed
Next
From: "A. Kretschmer"
Date:
Subject: Re: Help with "missing FROM clause" needed