on 2010 Dec 30 8:27 PM
Is there a way to get a description of a table or database object in isql besides copy/paste from sybase central? If I recall there is something similiar in MySQL, like DESC.
DESCRIBE [ [ INDEX FOR ] TABLE | PROCEDURE ] [ owner.]object-name
object-name: table, view, materialized view, procedure, or function
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Note that this is only available through dbisql. It is not a SQL statement.
If your using SA 11.0.1 or above, you can also use sa_get_table_definition(). See: http://dcx.sybase.com/index.html#1101en/dbreference_en11/sa-get-table-definition-sysproc.html
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Besides Vincent's suggestion, you can always query the system catalog to get information about any kind of database object.
For views, procedures and functions, this will also allow to get the description (i.e. the source code) and not just the list of columns/parameters as DESCRIBE does.
As you can use regular SQL queries to query the system catalog, you're free to select and join those system tables/views to extract every detail you're interested in.
Here's a good starting point in the V12 docs.
This question shows some examples, too.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
68 | |
8 | |
8 | |
7 | |
7 | |
6 | |
6 | |
6 | |
6 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.