Hallo zusammen
ich möchte ein Feld einer Tabelle ändern, und zwar mit den Bedingungen eines Selects.
Tabelle: tbtcp
Feld: sdluname
Bedingung zum update:
select count(*) from tbtco o, tbtcp p where o.jobcount=p.jobcount and o.status ='S';
--> 3
select count(*) from tbtco o, tbtcp p where o.jobcount=p.jobcount;
--> 185
Ich möchte nur bei den 3 rows den einen Wert in der Tabelle tbtcp ändern.
Versuch:
update tbtcp
set sdluname='SAP_BATCH_BC'
where exists (select p.sdluname from tbtco o, tbtcp p
where o.jobcount=p.jobcount and o.status ='S');
130 rows updated.
Leider nicht das gewünschte Resultat.
Hat jemand von euch ein Idee...
Gruss, Mr_Tom
ich möchte ein Feld einer Tabelle ändern, und zwar mit den Bedingungen eines Selects.
Tabelle: tbtcp
Feld: sdluname
Bedingung zum update:
select count(*) from tbtco o, tbtcp p where o.jobcount=p.jobcount and o.status ='S';
--> 3
select count(*) from tbtco o, tbtcp p where o.jobcount=p.jobcount;
--> 185
Ich möchte nur bei den 3 rows den einen Wert in der Tabelle tbtcp ändern.
Versuch:
update tbtcp
set sdluname='SAP_BATCH_BC'
where exists (select p.sdluname from tbtco o, tbtcp p
where o.jobcount=p.jobcount and o.status ='S');
130 rows updated.
Leider nicht das gewünschte Resultat.
Hat jemand von euch ein Idee...
Gruss, Mr_Tom