Chapter 3 Building Physical Diagrams


Assigning an alias to a table or a column

You can assign an alias to a table or a column. You use this alias in the query script instead of typing out the full code.

Steps To assign an alias to a table or a column:

  1. Double-click a view symbol to display the view property sheet.
  2. Click the SQL Query tab.

    The SQL Query page appears. It shows each SELECT query in the Query dropdown listbox. The text for a selected query appears in the textbox.
  3. Select a query from the Query dropdown listbox. This is the query that contains the SELECT statement to which you want to add an alias to a table or a column.
  4. Click the Properties tool from the tool bar at the top of the page.


    The property sheet for the SELECT query appears. The query definition is shown in the textbox.
  5. Click the Tables tab.

    or

    Click the Columns tab.

    The Table or Columns page appears.
  6. Click the number at the beginning of the line for the table or column to which you want to assign an alias.

    An arrow appears at the beginning of the line, and the line is highlighted.
  7. Click the Alias column for the same line.
  8. Type an alias in the Alias column.
  9. Click OK in each of the dialog boxes.

 


Copyright (C) 2005. Sybase Inc. All rights reserved.