The SQL page lets you build your SQL query.
If you are familiar with SQL queries, you can type in a query manually (using the Field Type and the Field drop-down lists to insert the fields you need). Details of the SQL statements allowed in InfoWorks WS Pro can be found in the SQL syntax topic.
Alternatively, you can click Builder >> to display a set of buttons representing the operators that you can include in your query.
You can represent constant values in the query by typing the name of a user macro instead of a value. User macros are highlighted in blue.
If you are viewing this page on the SQL dialog, see SQL dialog for further options.
Field | Description | ||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Object Type |
Drop-down list of the network object(s) for which you can write a SQL expression. |
||||||||||||||||||
Field Type
|
Drop-down list of the data fields that are applicable to the network object selected in the Object Type box. Selecting a field type from the list defines which fields will be available in the Field drop-down list:
|
||||||||||||||||||
Field |
Drop-down list of data fields applicable to the field type (parameter) selected in the Field Type box. Selecting a field from the list inserts the field in the query. When Field Type is set to <normal>, fields related to the selected object type will be displayed. In addition the following may be available:
Example SELECT oid,otypeon all links. Running this query will result in a grid listing each link and its type (such as 'conduit', 'pump', 'orifice', 'river', etc in InfoWorks CS) being displayed. ANY(us_links.otype<>'Conduit')on all nodes. This will select on the GeoPlan all the nodes for which any of the upstream links is not a conduit. Note: If running
InfoWorks WS Pro in a language other than English, it is important to note that the English words describing object types should be used and not their translation (for example, in the second query above, the word "Conduit" must be used, not its translation, for the query to work).
|
||||||||||||||||||
Display Flag Fields check box |
Check to include flag fields in the Field drop-down list. |
||||||||||||||||||
Search Type |
Drop-down list of available search types for use with the layers currently loaded in the GeoPlan. The available options are:
|
||||||||||||||||||
Distance |
This option becomes available when Distance is selected as the search type. Network objects within the search distance of a layer line or polygon area will be selected. |
||||||||||||||||||
Layer Type |
The Layer Type option becomes available when a spatial Search Type is selected.
|
||||||||||||||||||
Layer |
The Layer option becomes available when a spatial Search Type is selected. Drop-down list of layers currently loaded in the GeoPlan (only those layers loaded in the GeoPlan Window before the SQL dialog is opened will be listed). |
||||||||||||||||||
Field |
The Field option becomes available when a spatial Search Type is selected. Drop-down list of fields within the Layer selected in the Layer box. Selecting a spatial search Field from the list inserts the field in the query. |
||||||||||||||||||
Builder >> (button) |
Click to display a set of buttons representing the operators that can be included in the query. Click Finish << to close the builder. |