Introduction to the SQL Statement Builder

Many companies need the ability to interact with information in a relational database. They need to analyze, update, and display data often without in-depth knowledge of a database language like SQL. Proficy Portal can use data from the results of database statements or queries created by the SQL Statement Builder to construct applications that interact with a relational database.

In general, the SQL Statement Builder is a graphical interface from Proficy Portal to your relational database. It gives you the ability to design statements in the SQL language without the complexity of knowing or remembering the exact syntax required. It also allows the SQL expert to edit the text of a generated statement. In this way, the SQL Statement Builder is useful to all users.   

The statements are stored in a statement library and can be executed elsewhere during a Proficy Portal session. The SQL statements may include parameters to allow users to enter data at run time or to allow a single statement to be reused in a variety of displays. You can also use the text of SQL statements in other applications.

You can use SELECT statements created in the Statement Builder with Proficy Portal to access data in the following scenarios:

You can also use the SQL Statement Builder to create CALL, INSERT, UPDATE, and DELETE statements. Use these in applications to manipulate the data in your relational database in the following ways:

The statements you create serve as data sources to Proficy Portal objects. When you connect a statement to an object, Proficy Portal retrieves the requested data and displays it. Very often, however, you want to see if the statement is retrieving the data you think it is. To help you determine this, the Statement Builder also provides a testing feature so you can execute a statement without connecting it to an object.

The Statement Builder is designed to work with the latest ANSI-approved version of SQL. You can use it to access SQL Server, Oracle, DB2, and other relational databases.

For more information on using the SQL Statement Builder application, refer to the following sections: