I have two tables, for example:
TableA with columns GUID,ProgKey,UserKey,ProgName.
TableB with columns GUID,AppKey,ModeName. Foreign Key: GUID->TableA.GUID
I need to delete TableB.AppKey with specific value but only with the condition where TableA.UserKey= specific value.
I tried something simple like this but it didn't work:
Delete from TableB b, TableA a where b.AppKey=? and a.UserKey=?
And tried this, also didn't work:
Delete from TableB (AppKey) Select ? From TableB b, TableA a where a.UserKey=?
?=appkeyValue000
?=userkeyValue000
GUID is a primary key.