Modifying SQL SELECT statements

If the data source is SQL (such as Quick Select, SQL Select, or Query), you can graphically modify the SQL SELECT statement.

StepsTo modify a SQL data source:

  1. Select Design>Data Source from the menu bar.

    PocketBuilder returns you to the Select painter. (If you used Quick Select to define the data source, this might be the first time you have seen the Select painter.)

  2. Modify the SELECT statement graphically using the same techniques as were used when creating it.

    For more information, see “Using SQL Select”.

    NoteModifying the statement syntactically Select Design>Convert to Syntax from the menu bar to modify the SELECT statement syntactically.

  3. Click the Return button to return to the painter.

NoteChanging the table If you change the table referenced in the SELECT statement, PocketBuilder maintains the columns in the Design view (now from a different table) only if they match the data types and order of the columns in the original table.

Modifying the retrieval arguments

You can add, modify, or delete retrieval arguments when modifying your data source.

StepsTo modify the retrieval arguments:

  1. In the Select painter, select Design>Retrieval Arguments from the menu bar.

    The Specify Retrieval Arguments dialog box, displays listing the existing arguments.

  2. Add, modify, or delete the arguments.

  3. Click OK.

    You return to the Select painter, or to the text window displaying the SELECT statement if you are modifying the SQL syntactically.

  4. Reference any new arguments in the WHERE or HAVING clause of the SELECT statement.

For more information about retrieval arguments, see Chapter 17, “Defining DataWindow Objects.”