View Information in System Views

Information about views in a database is in the system view SYS.SYSVIEW.

See Reference: Building Blocks, Tables, and Procedures > System Tables and Views.

You can use Interactive SQL to browse the information in this view. Type the following statement in the dbisql command window to see all the columns in the SYS.SYSVIEW view:

SELECT * 
FROM SYS.SYSVIEW

To extract a text file containing the definition of a specific view, use a statement such as the following:

SELECT view_def FROM SYS.SYSVIEW 
WHERE view_object_id = 1583;
OUTPUT TO viewtext.sql
FORMAT ASCII