Beermann, Albert wrote
> 
> Hello Everbody
> 
> I have 3 tables
> Rbobjekte with rbobjekteid as primary key             = structured
> data
> Rbobjektpos with rbobjektposid as primary key and rbobjekteid = detail
> information of rbobjekte
> Rbaplposausf with rbaplposausfid as primary key and rbobjektposid =
> detail information of rbobjektpos
> 
> I have a dbproc creates a cursor ergebnis with all rbobjekteid from
> rbobjekte for a special structure
> 
> Now i want to update all the records of rbaplposausf belonging to all
> the rbobjektpos records belonging to all the rbobjektid in ergebnis
> 
> I do:
> Call dbproc ..
> 
> Update rbaplposausf set rbaplposausf.rbrevierid = ?l_wert  where
> rbaplposausf.rbobjektposid in (select rbobjektpos.rbobjektposid  from
> rbobjektpos where rbobjektpos.rbobjekteid in (select rbobjekteid from
> ergebnis))
> 
> Close ergebnis

Oops, I missed the first problem:
Update rbaplposausf set rbaplposausf.rbrevierid has to be changed to 
Update rbaplposausf set              rbrevierid   (no tablename allowed)

And the ?l_wert has (from a kernel's point of view) to be changed to
:l_wert. Perhaps ODBC will do something according to this, but  am not
sure.

And your subqueries should not cause any problem. 

Elke
SAP Labs Berlin

> 
> The update command fails with : missing delimiter
> 
> Can someone help me with the correct syntax for the update commands
> 
> Any help or ideas welcomed
> 
> Best regards
> Albert
> 
>                         '''''
>                       '''''''''
>                         (0 0)
>  +---------oOO-----------(_)------------------------------+
>  | Tel: 0541/5841-868                                     |
>  | Fax: 0541/5841-869                                     |
>  | Mail: mailto:[EMAIL PROTECTED]                 |
>  | Internet:  http://www.piepenbrock.de                   |
>  +--------------------------------------oOO---------------+
>                        |__|__|
>                         ||  ||
>                         ooO Ooo
> 
> --
> MaxDB Discussion Mailing List
> For list archives: http://lists.mysql.com/maxdb
> To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]


--
MaxDB Discussion Mailing List
For list archives: http://lists.mysql.com/maxdb
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to