db_load_sql_data (public)

 db_load_sql_data [ -dbn dbn ] [ -callback callback ] file

Defined in packages/acs-tcl/tcl/01-database-procs.tcl

Loads a CSV formatted file into a table using PostgreSQL's COPY command or Oracle's SQL*Loader utility. The filename format consists of a sequence number used to control the order in which tables are loaded, and the table name with "-" replacing "_". This is a bit of a kludge but greatly speeds the loading of large amounts of data, such as is done when various "ref-*" packages are installed.

Switches:
-dbn (optional)
The database name to use. If empty_string, uses the default database.
-callback (optional, defaults to "apm_ns_write_callback")
Parameters:
file (required)
Filename in the format dd-table-name.ctl where 'dd' is a sequence number used to control the order in which data is loaded. This file is an RDBMS-specific data loader control file.

Partial Call Graph (max 5 caller/called nodes):
%3 apm_package_install_data_model apm_package_install_data_model (private) db_load_sql_data db_load_sql_data apm_package_install_data_model->db_load_sql_data ref_timezones::apm::after_upgrade ref_timezones::apm::after_upgrade (private) ref_timezones::apm::after_upgrade->db_load_sql_data ad_file ad_file (public) db_load_sql_data->ad_file ad_tmpdir ad_tmpdir (public) db_load_sql_data->ad_tmpdir apm_callback_and_log apm_callback_and_log (public) db_load_sql_data->apm_callback_and_log db_driverkey db_driverkey (public) db_load_sql_data->db_driverkey db_get_database db_get_database (public) db_load_sql_data->db_get_database

Testcases:
No testcase defined.
[ show source ]
Show another procedure: