OpenSqlList Function

Help Contents


Opens a new query on the tag database.

Informal Syntax:

OpenSqlList( Title, AutoUpdate, SQL )

Formal Syntax:

OpenSqlList( Title:=Expression, AutoUpdate:=Expression, SQL:=Expression )


TitleANY_STRINGThe title of the SQL list.
AutoUpdate BOOL Whether the list automatically refreshes. Use TRUE to turn on automatic refresh. Use FALSE to turn off automatic refresh.
SQL ANY_STRING The SQL SELECT Query to display in the list. See SQL Language for the syntax of this parameter.

The OpenSqlList function executes an SQL query and displays the results in a table. The exact behaviour varies according to the context:

A program or script will not execute any statements after the OpenSQLList call.

Return Value



Displays a list of all digital tags:

OpenSqlList( "Digital Tags", TRUE, "SELECT FullName,DisplayValue FROM TagDataPointDigital" );

Further Information

Operator Actions

To learn where you can use this function.

Structured Text Function Call

To learn about calling a function from IEC 61131-3 structured text.

IEC 61131-3 Expressions

To learn about the different types of expression to use as function parameters.

SQL Language

To learn about the syntax of SQL statements in Fernhill SCADA.


For the meaning of terms used in Fernhill SCADA.