This content has been marked as final. Show 2 replies
David is correct in that this is the wrong forum, but a simple solution would be to use set theory with Oracle excels at. You don't need a temp table or truncate. The basic SQL statement would be...
delete from a
where a.content_id in (select a.content_id from a minus select b.content_id from b) /* give me all the rows that exist in A which don't exist in B */
If you take the rename talbe approach you will also to collect up all the grants, synonyms, indexes and other dependent objects and reissue those commands to put them back in place.