CASTOR migration: alternate implementation to fill the directories intermediate table with no temp table