What makes my situation difficult is that I don’t have a single column with a simple list of primary keys to delete (for example, “delete from the table where the key is located ([list]”). I have several columns together as the primary key and you will need to join them.
Using what I know about other databases, I thought it could be done like:
DELETE FROM
table1 t1
LEFT OUTER JOIN
table2 t2
ON
t2.key1 = t1.key1 AND
t2.key2 = t1.key2
WHERE
t2.key1 IS NULL;
But Teradata (v12) responds with error number 3706, saying: "Syntax error: input tables are not allowed in the FROM table."
source
share