Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

AVEVA™ InTouch HMI

Microsoft access database applications

  • Last UpdatedJun 17, 2024
  • 1 minute read

To communicate with Microsoft Access, you must connect to it by executing the SQLConnect() function in an InTouch QuickScript.

The SQLConnect() function is used to connect to Microsoft Access databases. Running a script containing the SQLConnect() function logs you on to the database server and opens a connection to allow other SQL functions to be run. The connection string used by SQLConnect() is formatted as follows:

SQLConnect(ConnectionId,"<attribute>=<value>;
<attribute>=<value>;...");

DSN is a unique attribute used by Microsoft Access and identifies the name of the data source as configured in the Microsoft ODBC Administrator.

SQLConnect(ConnectionId,"DSN=MSACC");

The valid data types that SQL Access Manager supports depends on the version of the ODBC driver being used.

Data Type

Length

Default

Range

Tag Type

text

255 characters

--

--

Message

number

--

--

--

Integer

number

--

--

--

Real

The text data type contains fixed length character strings and are used with InTouch Message tags. A length must be specified. Microsoft Access databases support text fields with a maximum length of 255 characters. InTouch Message tags are limited to 131 characters. If a message variable contains more characters than the length specified for a database field, the string will be truncated when inserted into the database. The Microsoft Access ODBC driver supports up to 17 characters per column name. The maximum number of columns supported when using SQLSetStatement( Select Col1, Col2, ...) is 40.

TitleResults for “How to create a CRG?”Also Available in