DELETE Problem mit zwei Tabellen
Tobias Mueller-Wrana
tobias at gfz-potsdam.de
Do Jun 5 12:01:46 CEST 2008
Nein nicht ganz, habe aber schon die korrigierte
Syntax geschickt
delete TABELLE_1, TABELLE_2 from TABELLE_1, TABELLE_2
where TABELLE_1.id = TABELLE_2.id and TABELLE_1.time <= DATE
TAB_1
id | value
---+------
1 | 23
1 | 34
2 | 22
2 | 45
3 | 34
TAB_2
id | date
---+------
1 | 2
2 | 6
3 | 4
4 | 1
bei
delete TAB_1, TAB_2 from TAB_1, TAB_2 where
TAB_1.id = TAB_2.id and TAB_2 < 5
sollte folgendes übrig bleiben
TAB_1
id | value
---+------
2 | 22
2 | 45
TAB_2
id | date
---+------
2 | 6
Tobias
------------------------------
Tobias Mueller-Wrana
GFZ Potsdam, Sektion 2.4, E256
Telegrafenberg. D-14773 Potsdam
Tel.: +49-(0)331-288-1241
-------------------------------