Displaying the underlying SQL statement

As you specify the data for the DataWindow object in Visual SQL, Sybase WorkSpace generates a SQL SELECT statement. It is this SQL statement that will be sent to the DBMS when you retrieve data into the DataWindow object. You can look at the SQL as it is being generated while you continue defining the data for the DataWindow object.

StepsTo display the SQL statement:

  1. Click the Preview tab to make the Preview view available, or select View>Preview if the Preview view is not currently displayed.

    You may need to use the scroll bar to see all parts of the SQL SELECT statement. This statement is updated each time you make a change.

Editing the SELECT statement syntactically

Instead of modifying the data source graphically, you can directly edit the SELECT statement in Visual SQL.

NoteConverting from syntax to graphics With some statements, it may not be possible to convert the syntax back to graphics mode. In general, once you convert the SQL statement to syntax, you should maintain it in syntax mode.

StepsTo edit the SELECT statement:

  1. Select Design>Convert to Syntax from the menu bar.

    Sybase WorkSpace displays the SELECT statement in a text window.

  2. Edit the SELECT statement.

  3. Do one of the following: