ASA Getting Started
System Tables
Another important system table is a view called SYSCOLUMNS. This is a readable form of the system table SYSCOLUMN. It describes all the columns in all the tables in the database. To see the contents of a table, type the following command, in which tablename represents the name of the table whose columns you wish to list:
SELECT * FROM sys.syscolumns WHERE tname = tablename
For example,
SELECT * FROM sys.syscolumns WHERE tname = 'employee' ORDER BY colno
This statement lists all the columns in the employee table. If you look at the columns to the right, you can see from the Coltype column that some columns in the employee table contain character information while others contain integer and date information.
You can also view columns in the Interactive SQL Lookup Table Name dialog, or in Sybase Central.
To view the columns in a table or view ( Interactive SQL )
Invoke the list of tables by pressing F7.
Select the table whose columns you wish to view.
Click Show Columns.
To view the columns in a table or view ( Sybase Central )
In the left pane of Sybase Central, select a database and open its Tables folder.
In the left pane, select a table.
In the right pane, click the Columns tab.
You can now view and modify the columns.