SAGA-GIS Tool Library Documentation (v9.1.2)

Tool Execute SQL

Execute SQL commands on a connected ODBC source. Separate different commands with a semicolon (';').

Parameters

 NameTypeIdentifierDescriptionConstraints
OptionsDSNText, CMDODBC_DSNData Source Name-
UserText, CMDODBC_USRUser Name-
PasswordText, CMDODBC_PWDPassword-
Server ConnectionChoice, GUICONNECTIONServer ConnectionAvailable Choices:
Default: 0
SQL StatmentLong textSQL-Default: CREATE TABLE myTable1 (Col1 VARCHAR(255) PRIMARY KEY, Col2 INTEGER);
INSERT INTO myTable1 (Col1, Col2) VALUES('First Value', 1);
DROP TABLE myTable1;
CommitBooleanCOMMIT-Default: 1
Stop on ErrorBooleanSTOP-Default: 0

Command-line

Usage: saga_cmd db_odbc 3 [-ODBC_DSN <str>] [-ODBC_USR <str>] [-ODBC_PWD <str>] [-SQL <str>] [-COMMIT <str>] [-STOP <str>]
  -ODBC_DSN:<str>	DSN
	Text, CMD
  -ODBC_USR:<str>	User
	Text, CMD
  -ODBC_PWD:<str>	Password
	Text, CMD
  -SQL:<str>     	SQL Statment
	Long text
	Default: CREATE TABLE myTable1 (Col1 VARCHAR(255) PRIMARY KEY, Col2 INTEGER);
INSERT INTO myTable1 (Col1, Col2) VALUES('First Value', 1);
DROP TABLE myTable1;

  -COMMIT:<str>  	Commit
	Boolean
	Default: 1
  -STOP:<str>    	Stop on Error
	Boolean
	Default: 0