We have a bunch of scripts to re-baseline our database. The script we run calls a bunch of other scripts:
@@set_target_schema
@@drop_all
-- do some other stuff - create tables, insert data, etc
commit;
set_target_schema.sql looks like:
define TARGET_SCHEMA="OUR_APP_NAME"
Is there any way to pass an optional parameter into our top-level script and then pass that parameter into set_target_schema.sql and use that value as the name of the schema if it's provided, otherwise use the default value?