This article provides instructions for installing online help for Transact-SQL syntax.The $SYBASE/$SYBASE_ASE/scripts directory contains scripts for installing syntax help database:ins_syn_sql.
1.Installing
Use following command to install:
- [sybase@syb01 ~]$ isql -Usa -P****** -Ssyb01 < /$SYBASE/$SYBASE_ASE/scripts/ins_syn_sql
2.Using online help:
- 1> sp_syntax 'alter'
- 2> go
- Syntax Help
- ------------------------------------------------------------------------------
- System Procedure
- sp_altermessage - Enables and disables the logging of a system-defined or
- user-defined message in the Adaptive Server error log.
- sp_altermessage message_id, parameter, parameter_value
- Transact-SQL
- alter database - Increases the amount of space allocated to a database.
- alter database database_name
- [on {default | database_device } [= size]
- [, database_device [= size]]...]
- [log on { default | database_device } [ = size ]
- [ , database_device [= size]]...]
- [with override]
- [for load]
- [for proxy_update]
- ..................................
- dbcc Procedure
- sp_dbcc_alterws - Changes the size of the specified workspace to a specified
- value, and initializes the workspace.
- sp_dbcc_alterws dbname, wsname, "wssize[K|M]"
- (return status = 0)
3.Troubleshooting
If the master device isn't the default device on sybase ASE,when you install the syntax database,the following occurs:
- There is not enough room in the default devices to create the sybsyntax database.
To fix it,you need to edit ins_syn_sql script and comment out the following lines like this:
- /*begin
- /* is the space left on the default database devices > size of model? */
- if (select sum (high-low +1) from sysdevices where status & 11 = 1)
- - (select sum (isnull (size, 0)) from sysusages, sysdevices
- where vstart >= sysdevices.low
- and vstart <= sysdevices.high
- and sysdevices.status &11 = 1
- and sysdevices.vdevno = sysusages.vdevno)
- > (select sum(sysusages.size) from sysusages where dbid = 3)
- begin
- if (@@maxpagesize = 1024 * 2)
- create database sybsyntax on default = 3
- else
- if (@@maxpagesize = 1024 * 4)
- create database sybsyntax on default = 6
- else
- create database sybsyntax on default
- end
- else
- begin
- /*
- ** 18047, "There is not enough room on the default devices to create the sybsyntax database."
- */
- raiserror 18047
- select syb_quit()
- end
- end*/
After commented out this entire section, add a line like this to the script:
- if not exists (select name from sysdatabases where name = "sybsyntax")
- create database sybsyntax on default
- go