You are here: Core Reference > Coding > QueryPad > TABLES Command

TABLES Command

You can use QueryPad’s TABLES command to display information about the tables that can be searched (on the system to which QueryPad is currently connected).

The tables used by ClearSCADA are grouped into sets, referred to as schemas. The schemas are used to organize the database into related groups, for example, there are schemas for every driver, Core tables, Historic tables, and so on.

To use the TABLES command:

  1. Display QueryPad
  2. Connect to the appropriate system (see Connect QueryPad to a Database)
  3. Enter the ?TABLES command followed by the arguments that are appropriate to your requirements. The correct syntax is:

    ?TABLES <Schema> <Table>

    Where:

    • <Schema> is the name of the group that contains the tables you want QueryPad to display. Do not include the angle brackets < >.
    • <Table> is the name of the table that you want QueryPad to display.

      If you specify an exact schema and table, then only the tables in that schema are listed. However, if you specify a pattern for a schema or table (by using the % character), then the tables that match the pattern are listed.

      Example:

      ?TABLES % %

      This will set QueryPad to list every table (the first % represents all schemas and the second % represents all tables)

      ?TABLES % %Point%

      This will set QueryPad to list every table that has ‘Point’ as part of its name (the first % represents every schema, and %Point% represents those tables that contain Point and any other characters as part of their name)

      TABLES AdvancedModbusSCADAPackModbus %Analog%

      This will set QueryPad to list those tables in the AdvancedModbusSCADAPackModbus schema that have Analog as part of their name.

      NOTE: The wildcards use the standard SQL LIKE syntax.

  4. Press the CTRL and the Enter keys simultaneously to submit your command.
    QueryPad displays a list of the tables that match the criteria specified in your command.

For each table in the list, QueryPad displays:


ClearSCADA 2015 R2