SQL query

Navigation:  Client commands > Tools > Client command editor > Command list >

SQL query

Version 1.0.0

Show hidden text

hmtoggle_arrow1SQL query

With this command you can make an SQL query to a database. For this purpose, you can use the SQL query tab. Here you can select whether the query should be run on ACMP server / database or on local computer. When local computer, a database connection can be defined to a SQL server.

 

5.8.3.2.25 - SQLquery 1

 

Under SQL execution mode, you can first specify whether it is in the SQL command to a call (execute) or a query (Open). The difference is that a SQL statement with the Open option returns a ResultSet (eg SELECT). A SQL statement with the Run option, however, provides only the number of rows affected (eg UPDATE). For stored procedures is also paying attention to the correct option. About the Automatic option ACMP attempts to discover from the statement, which of the two mode to use. Therefore, use the Automatic option as infrequently as possible.

 

In the SQL statement field, enter your query to by the common SQL standards. Furthermore, you have to specify a variable in which the query result is stored (see Variables).

 

5.8.3.2.25 - SQLquery 2

 

If the query is run on a local computer, a connection string must be created, which specifies the connection to the appropriate database. Click to create connection string on the button.

 

This opens a dialog in which you can choose if you use a Data Link file or want to use a connection string. In the Data Link file you will need a Microsoft Data Link file (*. Udl) or an ODBC DSN (*. Dsn) file. These can be accessed via a file selection dialog (Browse button).

 

5.8.3.2.25 - SQLquery 3

 

The path is written into the input line of the connection string, after which click on the button to convert connection settings from *. Udl file to transfer the data from the specified file to a matching string.

 

If you choose instead of the Data Link file for a connection string, you can set up on the Create button. For this purpose, another dialog opens: Under the tab Provider first select the driver (OLE DB Provider), which is the right one for your database. This multiple database types are supported. Under the Connections tab, you must enter the appropriate connection data (see note) while under the Advanced tab of a connection timeout and access permissions can be set.

 

A list of all parameters is provided under the tab All. Here, the parameters can be changed by double-clicking also.

 

Hinweis

Note:

The parameters to be specified under the tab connection vary depending on the selected driver. The relevant data are known to the respective database administrator, so that these will not be further explained here.

 

Various permissions under the Advanced tab also depending on the driver set. The settings for a layer of protection and impersonation are only available on certain drivers.

Last change on 10.03.2014