Invantive Data Hub is driven entirely from the command line. An argument is written as a slash, the name, a colon and the value: ``` /database:Demo\Dummy /file:c:\jobs\first-job.sql /interactive:false ``` Arguments may be given in any order, and every argument has a long and a short form. This product reads its own command line rather than the shared one of the other Invantive programs, so the separator is a colon here and an equals sign is not accepted. `/help` or `/?` prints the list below and ends with exit code 0; from release 27.0 onward it does so before the licence is loaded, so the list is also available on a device on which no licence has been registered yet. An argument in another format ends the program with `itgendhb002` and [[Invantive Data Hub/Exit Code|exit code]] 5; a leading dash instead of a slash is such a format. ## Arguments The following arguments are accepted: - `/database` (`/d`): the database, as `GROUP\NAME`. The older name `/connection` (`/c`) still works. - `/file` (`/f`): the file of Invantive UniversalSQL statements to execute. - `/user` (`/u`): the log-on code. - `/password` (`/p`): the password in plain text. - `/encryptedpassword` (`/e`): the password encrypted with the key of the device it runs on, encoded in Base64. - `/logfile` (`/l`): the file to write all output to. An existing file is appended to. - `/logoverwrite` (`/lo`): overwrite that file instead of appending. Default `false`. - `/verbose`: print extensive progress messages. This argument has no short form. - `/interactive` (`/i`): whether questions may be asked. Questions are asked unless `/interactive:false` is given, on which the run reports `itgendhb282`, "HEADLESS MODE REQUESTED", and answers nothing. A run on a console which is not interactive, such as a scheduled task, has to say so: without `/interactive:false` it ends with `itgendhb209`, "Use of headless mode is required when using a non-interactive console". - `/timestamp` (`/t`): leave the timestamp off the messages printed. Output carries a timestamp unless this argument is given. - `/licensekey` (`/lk`): use this licence key instead of the one in the user profile. - `/variables` (`/v`): one or more `NAME=VALUE` assignments to [[Invantive Script/Invantive Script|Invantive Script]] variables. - `/attributes` (`/a`): one or more `NAME=VALUE` assignments to the attributes of a data container. `/variables` and `/attributes` switch the reading of the rest of the command line: everything after them is read as assignments until the next slash argument. ## Naming a Data Container `/user`, `/password`, `/encryptedpassword` and `/attributes` may be followed by an at sign and the alias of a data container, as `/user@ecb:someone`. The value then applies to that container only. Without an alias the value applies to the container which has no alias. ## Log File Name The name of the log file may hold placeholders, which are expanded when the program starts, in the folder names as well as in the file name: - `%Y` year, `%j` day of the year (001–366), `%m` month, `%d` day of the month, `%u` day of the week (1–7); - `%H` hour, `%M` minute, `%S` second; - `%D` domain name, `%U` user name, `%h` machine name. ## Example Run a file against the database `invoicing` in group `WS203`, without interaction, with two provider attributes and one script variable: ``` /database:WS203\invoicing /file:c:\jobs\first-job.sql /interactive:false /attributes api-url=https://start2.exactonline.nl api-redirect-url=https://clientredirect.invantive.com /variables "MY_NAME=John Doe" ``` The variable is used in the statements as `${MY_NAME}`. ## Compliance `/password` puts a password on the command line, where the process list and the shell history can read it. Prefer an interactive log on, a pre-authenticated connection, or `/encryptedpassword`, which is bound to the device and useless elsewhere.