Scripting : sort domains and tables in dependency order (internal sort within category only). Script exceptions as well.