祝愿大家身体健康!

 站点注册  找回密码
 站点注册

QQ登录

只需一步,快速开始

查看: 6772|回复: 6

Quick Reference Guide for ASE

[复制链接]

Quick Reference Guide for ASE

[复制链接]
JohnPhan

主题

0

回帖

228

积分

注册会员

积分
228
贡献
在线时间
小时
2008-2-21 09:47:17 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?站点注册

×
http://pagesperso-orange.fr/laserquest/linux/refidx.html
共享共进共赢Sharing And Win-win Results
SYBASEBBS - 免责申明1、欢迎访问“SYBASEBBS.COM”,本文内容及相关资源来源于网络,版权归版权方所有!本站原创内容版权归本站所有,请勿转载!
2、本文内容仅代表作者观点,不代表本站立场,作者自负,本站资源仅供学习研究,请勿非法使用,否则后果自负!请下载后24小时内删除!
3、本文内容,包括但不限于源码、文字、图片等,仅供参考。本站不对其安全性,正确性等作出保证。但本站会尽量审核会员发表的内容。
4、如本帖侵犯到任何版权问题,请立即告知本站 ,本站将及时删除并致以最深的歉意!客服邮箱:admin@sybasebbs.com
ehxz

主题

0

回帖

59万

积分

管理员

积分
590891
贡献
在线时间
小时
2008-2-21 10:14:07 | 显示全部楼层

Quick Reference Guide for ASE

Dbcc Stored Procs

 
sp_dbcc_alterws 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]" 
sp_dbcc_configreport sp_dbcc_configreport - Generates a report that describes the configuration information used by the dbcc checkstorage operation for the specified database. sp_dbcc_configreport [dbname] 
sp_dbcc_createws sp_dbcc_createws - Creates a workspace of the specified type and size on the specified segment and database. sp_dbcc_createws dbname, segname, [wsname], wstype, "wssize[K|M]" 
sp_dbcc_deletedb sp_dbcc_deletedb - Deletes from dbccdb all the information related to the specified target database. sp_dbcc_deletedb [dbname] 
sp_dbcc_deletehistory sp_dbcc_deletehistory - Deletes the results of dbcc checkstorage operations performed on the target database before the specified date and time. sp_dbcc_deletehistory [cutoffdate [, dbname]] 
sp_dbcc_differentialreport sp_dbcc_differentialreport - Generates a report that highlights the changes I/O statistics and faults that took place between two dbcc operations. sp_dbcc_differentialreport [dbname [, objectname]], [db_op] [, "date1" [, "date2"]] 
sp_dbcc_evaluatedb sp_dbcc_evaluatedb - Recomputes configuration information for the target database and compares it to the current configuration information. sp_dbcc_evaluatedb [dbname] 
sp_dbcc_faultreport sp_dbcc_faultreport - Generates a report covering fault statistics for the dbcc checkstorage operations performed for the specified object in the target database on the specified date. sp_dbcc_faultreport [dbname [, objectname [, date [, "short" | "long"]]]] 
sp_dbcc_fullreport sp_dbcc_fullreport - Runs sp_dbcc_summaryreport, sp_dbcc_configreport, sp_dbcc_statisticsreport, and sp_dbcc_faultreport short for database..object_name on or before the specified date. sp_dbcc_fullreport [dbname [, objectname [, date]]] 
sp_dbcc_runcheck sp_dbcc_runcheck - Runs dbcc checkstorage on the specified database, and then runs sp_dbcc_summaryreport or a report you specify. sp_dbcc_runcheck dbname [, user_proc] 
sp_dbcc_statisticsreport sp_dbcc_statisticsreport - Generates an allocation statistics report on the specified object in the target database. sp_dbcc_statisticsreport [dbname [, objectname [, date]]] 
sp_dbcc_summaryreport sp_dbcc_summaryreport - Generates a summary report on the specified database. sp_dbcc_summaryreport [dbname [, date]] 
sp_dbcc_updateconfig sp_dbcc_updateconfig - Updates the dbcc_config table in dbccdb with the configuration information of the target database. sp_dbcc_updateconfig dbname, type, "str1" [, "str2"] 

[此贴子已经被作者于2008-2-21 10:14:47编辑过]
共享共进共赢Sharing And Win-win Results
ehxz

主题

0

回帖

59万

积分

管理员

积分
590891
贡献
在线时间
小时
2008-2-21 10:15:02 | 显示全部楼层

Quick Reference Guide for ASE


 

ESP Commands
 

xp_cmdshell xp_cmdshell - Executes a native operating system command on the host system running Adaptive Server. xp_cmdshell command [, no_output] 
xp_deletemail xp_deletemail - Deletes a message from the Adaptive Server message inbox. xp_deletemail [msg_id] 
xp_enumgroups xp_enumgroups - Displays groups for a specified Windows NT domain. xp_enumgroups [domain_name] 
xp_findnextmsg xp_findnextmsg - Retrieves the next message identifier from the Adaptive Server message inbox. xp_findnextmsg @msg_id = @msg_id output [, type] [, unread_only = {true | false}] 
xp_logevent xp_logevent - Provides for logging a user-defined event in the Windows NT Event Log from within Adaptive Server. xp_logevent error_number, message [, type] 
xp_readmail xp_readmail - Reads a message from the Adaptive Server message inbox. xp_readmail [msg_id] [, recipients output] [, sender output] [, date_received output] [, subject output] [, cc output] [, message output] [, attachments output] [, suppress_attach = {true | false}] [, peek = {true | false}] [, unread = {true | false}] [, msg_length output] [, bytes_to_skip [output]] [, type [output]] 
xp_sendmail xp_sendmail - Sends a message to the specified recipients. The message is either text or the results of a Transact-SQL query. xp_sendmail recipient [, recipient] . . . [, subject] [, cc_recipient] . . . [, bcc_recipient] . . . [, {query | message}] [, attachname] [, attach_result = {true | false}] [, echo_error = {true | false}] [, include_file [, include_file] . . .] [, no_column_header = {true | false}] [, width] [, separator] [, dbuser] [, dbname] [, type] [, include_query = {true | false}] 
xp_startmail xp_startmail - Starts an Adaptive Server mail session. xp_startmail [mail_user] [, mail_password] 
xp_stopmail xp_stopmail - Stops an Adaptive Server mail session. xp_stopmail 

 

共享共进共赢Sharing And Win-win Results
ehxz

主题

0

回帖

59万

积分

管理员

积分
590891
贡献
在线时间
小时
2008-2-21 10:16:03 | 显示全部楼层

Quick Reference Guide for ASE


 



Unix Utilities
 

backupserver backupserver - The executable form of the Backup Server program. backupserver [-Cserver_connections] [-Sb_servername] [-Iinterfaces_file] [-eerror_log_file] [-Msybmultbuf_binary] [-Nnetwork_connections] [-Ttrace_value] [-LSybase_language_name] [-JSybase_character_set_name] [-ctape_config_file] [-V{0|1|2|3}] or backupserver -v 
bcp bcp - Copies a database table to or from an operating system file in a user- specified format. bcp [[database_name.]owner.][view_name | table_name [:partition_id]] {in | out} datafile [-c] [-E] [-n] [-N] [-X] [-a display_charset] [-A packet_size] [-b batchsize] [-e errfile] [-f formatfile] [-g id_start_value] [-I interfaces_file] [-J client_charset] [-m maxerrors] [-P password] [-q datafile_charset] [-R remote_server_principal] [-S server] [-t field_terminator] [-T text_or_image_size] [-U username] [-z language] or bcp -v 
buildmaster buildmaster - Builds the master device and creates the master, model, and tempdb databases on the device. buildmaster [-d disk] [-c cno] [-s size] [-m] [-r] [-q] [-x] or buildmaster -v 
dataserver dataserver - The executable form of the Adaptive Server program. dataserver -ddevicename [-cconfigurationfile] [-eerrorlogfile] [-m] [-rmastermirror] [-Msharedmem_directory] [-iinterfaces_file_directory] [-sservername] [-psso_login_name] or dataserver -v 
defncopy defncopy - Copies definitions for specified views, rules, defaults, triggers, or procedures from a database to an operating system file or from an operating system file to a database. The defncopy utility cannot copy table definitions or reports created with Report Workbench. defncopy [-X] [-a display_charset] [-I interfaces_file] [-J [client_charset]] [-P password] [-R remote_server_principal] [-S [server]] [-U username] [-z language] {in filename dbname | out filename dbname [owner.]objectname [[owner.]objectname...] } or defncopy -v 
dscp dscp - Allows you to view and edit server entries in the interfaces file from the command line. dscp [-p] or dscp -v To exit from dscp: quit or exit 
dsedit dsedit - Allows you to view and edit server entries in the interfaces file using a graphical user interface based on X11/Motif. dsedit or dsedit -v 
isql isql - Interactive SQL parser to Adaptive Server. isql [-b] [-e] [-F] [-n] [-p] [-X] [-Y] [-a display_charset] [-A size] [-c cmdend] [-D database] [-E editor] [-h headers] [-H hostname] [-i inputfile] [-I interfaces_file] [-J client_charset] [-l login_timeout] [-m errorlevel] [-o outputfile] [-P password] [-R remote_server_principal] [-s colseparator] [-S server] [-t timeout] [-U username] [-w columnwidth] [-z language] or isql -v To terminate a command: go To clear the query buffer: reset To call the default editor: vi To execute an operating system command: !! command To exit from isql: quit or exit 
langinstall langinstall - Installs a new language in an Adaptive Server. langinstall [-S server] [-I interfaces_file] [-P password] [-R release_number] language character_set or langinstall -v 
optdiag optdiag - Displays optimizer statistics or loads updated statistics into system tables. optdiag [ binary ] [simulate ] statistics { -i input_file | database[.owner[.[table[.column]]]] [-o output_file] } [-U username] [-P password] [-I interfaces_file] [-S server] [-v] [-h] [-Tflag_value] [-z language] [-J client_charset] [-a display_charset] 
showserver showserver - Shows the Adaptive Servers and Backup Servers that are currently running on the local machine. showserver 
sqlloc sqlloc - Installs and modifies languages, character sets, and sort order defaults for Adaptive Server using a graphical user interface based on X11/Motif. sqlloc [-S server] [-U user] [-P password] [-s sybase_dir] [-I interfaces_file] [-r resource_file] or sqlloc -v 
sqllocres sqllocres - Installs and modifies languages, character sets, and sort order defaults for Adaptive Server, using a resource file. sqllocres [-S server] [-U user] [-P password] [-s sybase_dir] [-I interfaces_file] [-r resource_file] or sqllocres -v 
sqlupgrade sqlupgrade - Upgrades your currently installed release of Adaptive Server to the newest release using a graphical user interface based on X11/Motif. sqlupgrade [-s sybase_dir] [-r resource_file] or sqlupgrade -v 
sqlupgraderes sqlupgraderes - Upgrades your currently installed release of Adaptive Server to the newest release using resource files. sqlupgraderes [-s sybase_dir] [-r resource_file] or sqlupgraderes -v 
srvbuild srvbuild - Creates a new Adaptive Server, Backup Server, Monitor Server, or XP Server with default or user-specified values for key configuration attributes using a graphical user interface based on X11/Motif. srvbuild [-s sybase_dir] [-I interfaces_file] [-r resource_file] or srvbuild -v 
srvbuildres srvbuildres - Creates, using resource files, a new Adaptive Server, Backup Server, Monitor Server, or XP Server with default or user-specified values for key configuration attributes. srvbuildres [-s sybase_dir] [-I interfaces_file] [-r resource_file] or srvbuildres -v 
startserver startserver - Starts an Adaptive Server and/or a Backup Server. startserver [[-f runserverfile] [-m]] ... 
sybload sybload - Uploads Sybase products from the distribution media and builds the Sybase installation directory. sybload [-D] 
sybsetup sybsetup - Installs and configures Adaptive Server from a single location using a graphical user interface based on X11/Motif. sybsetup [-c devicename] [-t devicename] [-l local_source] [-r remote_source] 

共享共进共赢Sharing And Win-win Results
ehxz

主题

0

回帖

59万

积分

管理员

积分
590891
贡献
在线时间
小时
2008-2-21 10:18:42 | 显示全部楼层

Quick Reference Guide for ASE


 

System Stored Procs
 

sp_activeroles sp_activeroles - Displays all active roles. sp_activeroles [expand_down] 
sp_add_resource_limit sp_add_resource_limit - Creates a limit on the number of server resources that can be used by an Adaptive Server login and/or an application to execute a query, query batch, or transaction. sp_add_resource_limit name, appname, rangename, limittype, limitvalue [, enforced [, action [, scope ]]] 
sp_add_time_range sp_add_time_range - Adds a named time range to an Adaptive Server. sp_add_time_range name, startday, endday, starttime, endtime 
sp_addalias sp_addalias - Allows an Adaptive Server user to be known in a database as another user. sp_addalias loginame, name_in_db 
sp_addauditrecord sp_addauditrecord - Allows users to enter user-defined audit records (comments) into the audit trail. sp_addauditrecord [text] [, db_name] [, obj_name] [, owner_name] [, dbid] [, objid] 
sp_addaudittable sp_addaudittable - Adds another system audit table after auditing is installed. sp_addaudittable devname 
sp_addengine sp_addengine - Adds an engine to an existing engine group or, if the group does not exist, creates an engine group and adds the engine. sp_addengine engine_number, engine_group 
sp_addexeclass sp_addexeclass - Creates or updates a user-defined execution class that you can bind to client applications, logins, and stored procedures. sp_addexeclass classname, priority, timeslice, engine_group 
sp_addextendedproc sp_addextendedproc - Creates an extended stored procedure (ESP) in the master database. sp_addextendedproc esp_name, dll_name 
sp_addexternlogin sp_addexternlogin - Creates an alternate login account and password to use when communicating with a remote server through Component Integration Services. sp_addexternlogin server, loginname, externname [, externpassword] 
sp_addgroup sp_addgroup - Adds a group to a database. Groups are used as collective names in granting and revoking privileges. sp_addgroup grpname 
sp_addlanguage sp_addlanguage - Defines the names of the months and days for an alternate language and its date format. sp_addlanguage language, alias, months, shortmons, days, datefmt, datefirst 
sp_addlogin sp_addlogin - Adds a new user account to Adaptive Server. sp_addlogin loginame, passwd [, defdb [, deflanguage [, fullname]]] 
sp_addmessage sp_addmessage - Adds user-defined messages to sysusermessages for use by stored procedure print and raiserror calls and by sp_bindmsg. sp_addmessage message_num, message_text [, language] [, with_log] [, replace] 
sp_addobjectdef sp_addobjectdef - Specifies the mapping between a local table and an external storage location. sp_addobjectdef tablename, "objectdef" [,"objecttype"] 
sp_addremotelogin sp_addremotelogin - Authorizes a new remote server user by adding an entry to master.dbo.sysremotelogins. sp_addremotelogin remoteserver [, loginame [, remotename] ] 
sp_addsegment sp_addsegment - Defines a segment on a database device in a database. sp_addsegment segname, dbname, devname 
sp_addserver sp_addserver - Defines a remote server, or defines the name of the local server. sp_addserver lname [, class [, pname]] 
sp_addthreshold sp_addthreshold - Creates a threshold to monitor space on a database segment. When free space on the segment falls below the specified level, Adaptive Server executes the associated stored procedure. sp_addthreshold dbname, segname, free_space, proc_name 
sp_addtype sp_addtype - Creates a user-defined datatype. sp_addtype typename, phystype [(length) | (precision [, scale])] [, "identity" | nulltype] 
sp_addumpdevice sp_addumpdevice - Adds a dump device to Adaptive Server. sp_addumpdevice {"tape" | "disk"}, logicalname, physicalname [, tapesize] 
sp_adduser sp_adduser - Adds a new user to the current database. sp_adduser loginame [, name_in_db [, grpname]] 
sp_altermessage 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 
sp_audit sp_audit - Allows a System Security Officer to configure auditing options. sp_audit option, login_name, object_name [,setting] 
sp_autoconnect sp_autoconnect - Defines a passthrough connection to a remote server for a specific user, which allows the named user to enter passthrough mode automatically at login. sp_autoconnect server, {true|false} [, loginame] 
sp_bindcache sp_bindcache - Binds a database, table, index, text object, or image object to a data cache. sp_bindcache cachename, dbname [, [ownername.]tablename [, indexname | "text only"]] 
sp_bindefault sp_bindefault - Binds a user-defined default to a column or user-defined datatype. sp_bindefault defname, objname [, futureonly] 
sp_bindexeclass sp_bindexeclass - Associates an execution class with a client application, login, or stored procedure. sp_bindexeclass "object_name", "object_type", "scope", "classname" 
sp_bindmsg sp_bindmsg - Binds a user message to a referential integrity constraint or check constraint. sp_bindmsg constrname, msgid 
sp_bindrule sp_bindrule - Binds a rule to a column or user-defined datatype. sp_bindrule rulename, objname [, futureonly] 
sp_cacheconfig sp_cacheconfig - Creates, configures, reconfigures, and drops data caches, and provides information about them. sp_cacheconfig [cachename [ ,"cache_size[P|K|M|G]" ] [,logonly | mixed ] [,strict | relaxed ] ] 
sp_cachestrategy sp_cachestrategy - Enables or disables prefetching (large I/O) and MRU cache replacement strategy for a table, index, text object, or image object. sp_cachestrategy dbname, [ownername.]tablename [, indexname | "text only" | "table only" [, { prefetch | mru }, { "on" | "off"}]] 
sp_changedbowner sp_changedbowner - Changes the owner of a user database. sp_changedbowner loginame [, true ] 
sp_changegroup sp_changegroup - Changes a user's group. sp_changegroup grpname, username 
sp_checknames sp_checknames - Checks the current database for names that contain characters not in the 7-bit ASCII set. sp_checknames 
sp_checkreswords sp_checkreswords - Detects and displays identifiers that are Transact-SQL reserved words. Checks server names, device names, database names, segment names, user-defined datatypes, object names, column names, user names, login names, and remote login names. sp_checkreswords [user_name_param] 
sp_checksource sp_checksource - Checks for the existence of the source text of the compiled object. sp_checksource [objname [, tabname [, username]]] 
sp_chgattribute space allocations of a table or an index. Sets the concurrency_opt_threshold for a table. concurrency_opt_threshold }, optvalue 
sp_clearpsexe sp_clearpsexe - Clears the execution attributes of an Adaptive Server session that was set by sp_setpsexe. sp_clearpsexe spid, exeattr 
sp_clearstats sp_clearstats - Initiates a new accounting period for all server users or for a specified user. Prints statistics for the previous period by executing sp_reportstats. sp_clearstats [loginame] 
sp_column_privileges sp_column_privileges - Returns permissions information for one or more columns in a table or view. sp_column_privileges table_name [, table_owner [, table_qualifier [, column_name]]] 
sp_columns sp_columns - Returns information about the type of data that can be stored in one or more columns. sp_columns table_name [, table_owner ] [, table_qualifier] [, column_name] 
sp_commonkey sp_commonkey - Defines a common key-columns that are frequently joined-between two tables or views. sp_commonkey tabaname, tabbname, col1a, col1b [, col2a, col2b, ..., col8a, col8b] 
sp_configure sp_configure - Displays or changes configuration parameters. sp_configure [configname [, configvalue] | group_name | non_unique_parameter_fragment] sp_configure "configuration file", 0, {"write" | "read" | "verify" | "restore"} "file_name" 
sp_countmetadata sp_countmetadata - Displays the number of indexes, objects, or databases in Adaptive Server. sp_countmetadata "configname" [, dbname] 
sp_cursorinfo sp_cursorinfo - Reports information about a specific cursor or all cursors that are active for your session. sp_cursorinfo [{cursor_level | null}] [, cursor_name] 
sp_databases sp_databases - Returns a list of databases in Adaptive Server. sp_databases 
sp_datatype_info sp_datatype_info - Returns information about a particular ODBC datatype or about all ODBC datatypes. sp_datatype_info [data_type] 
sp_dboption sp_dboption - Displays or changes database options. sp_dboption [dbname, optname, {true | false}] 
sp_dbrecovery_order sp_dbrecovery_order - Specifies the order in which individual user databases are recovered and lists the user-defined recovery order of an individual database or all databases. sp_dbrecovery_order [database_name [, rec_order [, force]]] 
sp_dbremap sp_dbremap - Forces Adaptive Server to recognize changes made by alter database. Run this procedure only when instructed to do so by an Adaptive Server message. sp_dbremap dbname 
sp_defaultloc sp_defaultloc - Defines a default storage location for objects in a local database. sp_defaultloc dbname, {"defaultloc"| NULL} [, "defaulttype"] 
sp_depends sp_depends - Displays information about database object dependencies-the view(s), trigger(s), and procedure(s) in the database that depend on a specified table or view, and the table(s) and view(s) in the database on which the specified view, trigger, or procedure depends. sp_depends objname 
sp_diskdefault sp_diskdefault - Specifies whether or not a database device can be used for database storage if the user does not specify a database device or specifies default with the create database or alter database commands. sp_diskdefault logicalname, {defaulton | defaultoff} 
sp_displayaudit sp_displayaudit - Displays the active audit options. sp_displayaudit [procedure | object | login | database | global | default_object | default_procedure [, "name"]] 
sp_displaylevel sp_displaylevel - Sets or shows which Adaptive Server configuration parameters appear in sp_configure output. sp_displaylevel [loginame [, level]] 
sp_displaylogin sp_displaylogin - Displays information about a login account. Also displays information about the hierarchy tree above or below the login account when you so specify. sp_displaylogin [loginame [, expand_up | expand_down]] 
sp_displayroles sp_displayroles - Displays all roles granted to another role, or displays the entire hierarchy tree of roles in table format. sp_displayroles {login_name | rolename [, expand_up | expand_down]} 
sp_drop_resource_limit sp_drop_resource_limit - Removes one or more resource limits from Adaptive Server. sp_drop_resource_limit {name, appname } [, rangename, limittype, enforced, action, scope] 
sp_drop_time_range sp_drop_time_range - Removes a user-defined time range from Adaptive Server. sp_drop_time_range name 
sp_dropalias sp_dropalias - Removes the alias user name identity established with sp_addalias. sp_dropalias loginame 
sp_dropdevice sp_dropdevice - Drops an Adaptive Server database device or dump device. sp_dropdevice logicalname 
sp_dropengine sp_dropengine - Drops an engine from a specified engine group or, if the engine is the last one in the group, drops the engine group. sp_dropengine engine_number, engine_group 
sp_dropexeclass sp_dropexeclass - Drops a user-defined execution class. sp_dropexeclass classname 
sp_dropextendedproc sp_dropextendedproc - Removes an extended stored procedure (ESP). sp_dropextendedproc esp_name 
sp_dropexternlogin sp_dropexternlogin - Drops the definition of a remote login previously defined by sp_addexternlogin. sp_dropexternlogin remote_server [, login_name] 
sp_dropglockpromote sp_dropglockpromote - Removes lock promotion values from a table or database. sp_dropglockpromote {"database" | "table"}, objname 
sp_dropgroup sp_dropgroup - Drops a group from a database. sp_dropgroup grpname 
sp_dropkey sp_dropkey - Removes from the syskeys table a key that had been defined using sp_primarykey, sp_foreignkey, or sp_commonkey. sp_dropkey keytype, tabname [, deptabname] 
sp_droplanguage sp_droplanguage - Drops an alternate language from the server and sp_droplanguage language [, dropmessages] 
sp_droplogin sp_droplogin - Drops an Adaptive Server user login by deleting the user's entry from master.dbo.syslogins. sp_droplogin loginame 
sp_dropmessage sp_dropmessage - Drops user-defined messages from sysusermessages. sp_dropmessage message_num [, language] 
sp_dropobjectdef sp_dropobjectdef - Deletes the external storage mapping provided for a local object. sp_dropobjectdef "object_name" 
sp_dropremotelogin sp_dropremotelogin - Drops a remote user login. sp_dropremotelogin remoteserver [, loginame [, remotename] ] 
sp_droprowlockpromote a database or table. 
sp_dropsegment sp_dropsegment - Drops a segment from a database or unmaps a segment from a particular database device. sp_dropsegment segname, dbname [, device] 
sp_dropserver sp_dropserver - Drops a server from the list of known servers or drops remote logins and external logins in the same operation. sp_dropserver server [, droplogins] 
sp_dropthreshold sp_dropthreshold - Removes a free-space threshold from a segment. sp_dropthreshold dbname, segname, free_space 
sp_droptype sp_droptype - Drops a user-defined datatype. sp_droptype typename 
sp_dropuser sp_dropuser - Drops a user from the current database. sp_dropuser name_in_db 
sp_estspace sp_estspace - Estimates the amount of space required for a table and its indexes, and the time needed to create the index. [, cols_to_max [, textbin_len [, iosec]]]] 
sp_extendsegment sp_extendsegment - Extends the range of a segment to another database device. sp_extendsegment segname, dbname, devname 
sp_familylock sp_familylock - Reports information about all the locks held by a family (coordinating process and its worker processes) executing a statement in parallel. sp_familylock [fpid1 [, fpid2]] 
sp_fkeys sp_fkeys - Returns information about foreign key constraints created with the create table or alter table command in the current database. sp_fkeys pktable_name [, pktable_owner] [, pktable_qualifier] [, fktable_name] [, fktable_owner] [, fktable_qualifier] 
sp_flushstats sp_flushstats - Flushes statistics from in-memory storage to the systabstats system table. sp_flushstats objname 
sp_forceonline_db sp_forceonline_db - Provides access to all the pages in a database that were previously marked suspect by recovery. sp_forceonline_page dbname, {"sa_on" | "sa_off" | "all_users"} 
sp_forceonline_object sp_forceonline_object - Provides access to an index previously marked suspect by recovery. sp_forceonline_object dbname, objname, indid, {sa_on | sa_off | all_users} [, no_print] 
sp_forceonline_page sp_forceonline_page - Provides access to pages previously marked suspect by recovery. sp_forceonline_page dbname, pgid, {"sa_on" | "sa_off" | "all_users"} 
sp_foreignkey sp_foreignkey - Defines a foreign key on a table or view in the current database. sp_foreignkey tabname, pktabname, col1 [, col2] ... [, col8] 
sp_freedll sp_freedll - Unloads a dynamic link library (DLL) that was previously loaded into XP Server memory to support the execution of an extended stored procedure (ESP). sp_freedll dll_name 
sp_getmessage sp_getmessage - Retrieves stored message strings from sysmessages and sysusermessages for print and raiserror statements. sp_getmessage message_num, result output [, language] 
sp_grantlogin sp_grantlogin - Assigns Adaptive Server roles or default permissions to Windows NT users and groups when Integrated Security mode or Mixed mode (with Named Pipes) is active. sp_grantlogin {login_name | group_name} ["role_list" | default] 
sp_help for tables. sp_help table_name 
sp_help_resource_limit sp_help_resource_limit - Reports on resource limits. sp_help_resource_limit [name [, appname [, limittime [, limitday [, scope [, action]]]]]] 
sp_helpartition sp_helpartition - Lists the partition number, first page, control page, and number of data pages and summary size information for each partition in a partitioned table. sp_helpartition [table_name] 
sp_helpcache sp_helpcache - Displays information about the objects that are bound to a data cache or the amount of overhead required for a specified cache size. sp_helpcache {cache_name | "cache_size[P|K|M|G]"} 
sp_helpconfig sp_helpconfig - Reports help information on configuration parameters. sp_helpconfig "configname", ["size"] 
sp_helpconstraint sp_helpconstraint - Reports information about integrity constraints used in the specified tables. sp_helpconstraint [objname] [, detail] 
sp_helpdb database. sp_helpdb [dbname] 
sp_helpdevice sp_helpdevice - Reports information about a particular device or about all Adaptive Server database devices and dump devices. sp_helpdevice [devname] 
sp_helpextendedproc sp_helpextendedproc - Displays extended stored procedures (ESPs) in the current database, along with their associated DLL files. sp_helpextendedproc [esp_name] 
sp_helpexternlogin sp_helpexternlogin - Reports information about external login names. sp_helpexternlogin [remote_server [, login_name]] 
sp_helpgroup sp_helpgroup - Reports information about a particular group or about all groups in the current database. sp_helpgroup [grpname] 
sp_helpindex sp_helpindex - Reports new information about the indexes created on a table. sp_helpindex objname 
sp_helpjoins sp_helpjoins - Lists the columns in two tables or views that are likely join candidates. sp_helpjoins lefttab, righttab 
sp_helpkey sp_helpkey - Reports information about a primary, foreign, or common key of a particular table or view, or about all keys in the current database. sp_helpkey [tabname] 
sp_helplanguage sp_helplanguage - Reports information about a particular alternate language or about all languages. sp_helplanguage [language] 
sp_helplog sp_helplog - Reports the name of the device that contains the first page of the transaction log. sp_helplog 
sp_helpobjectdef sp_helpobjectdef - Reports owners, objects, and type information for remote object definitions. sp_helpobjectdef [object_name] 
sp_helpremotelogin sp_helpremotelogin - Reports information about a particular remote server's logins or about all remote server logins. sp_helpremotelogin [remoteserver [, remotename]] 
sp_helprotect sp_helprotect - Reports on permissions for database objects, users, groups, or roles. sp_helprotect [name [, username [, "grant" [,"none"|"granted"|"enabled"|role_name]]]] 
sp_helpsegment sp_helpsegment - Reports information about a particular segment or about all segments in the current database. sp_helpsegment [segname] 
sp_helpserver sp_helpserver - Reports information about a particular remote server or about all remote servers. sp_helpserver [server] 
sp_helpsort sp_helpsort - Displays Adaptive Server's default sort order and character set. sp_helpsort 
sp_helptext sp_helptext - Displays the source text of a compiled object. sp_helptext objname 
sp_helpthreshold sp_helpthreshold - Reports the segment, free-space value, status, and stored procedure associated with all thresholds in the current database or all thresholds for a particular segment. sp_helpthreshold [segname] 
sp_helpuser sp_helpuser - Reports information about a particular user, group, or alias, or about all users, in the current database. sp_helpuser [name_in_db] 
sp_hidetext sp_hidetext - Hides the source text for the specified compiled object. sp_hidetext [objname [, tabname [, username]]] 
sp_indsuspect sp_indsuspect - Checks user tables for indexes marked as suspect during recovery following a sort order change. sp_indsuspect [tab_name] 
sp_listsuspect_db sp_listsuspect_db - Lists all databases that currently have offline pages because of corruption detected on recovery. sp_listsuspect_db 
sp_listsuspect_object sp_listsuspect_object - Lists all indexes in a database that are currently offline because of corruption detected on recovery. sp_listsuspect_object [dbname] 
sp_listsuspect_page sp_listsuspect_page - Lists all pages in a database that are currently offline because of corruption detected on recovery. sp_listsuspect_page [dbname] 
sp_lock sp_lock - Reports additional information about processes that currently hold locks. sp_lock [spid1 [, spid2]] 
sp_locklogin sp_locklogin - Locks an Adaptive Server account so that the user cannot log in or displays a list of all locked accounts. sp_locklogin [loginame, "{lock | unlock}"] 
sp_logdevice sp_logdevice - Moves the transaction log of a database with log and data on the same device to a separate database device. sp_logdevice dbname, devname 
sp_loginconfig sp_loginconfig - Displays the value of one or all integrated security parameters. sp_loginconfig ["parameter_name"] 
sp_logininfo sp_logininfo - Displays all roles granted to Windows NT users and groups with sp_grantlogin. sp_logininfo ["login_name" | "group_name"] 
sp_logiosize sp_logiosize - Changes the log I/O size used by Adaptive Server to a different memory pool when doing I/O for the transaction log of the current database. sp_logiosize ["default" | "size" | "all"] 
sp_modify_resource_limit sp_modify_resource_limit - Changes a resource limit by specifying a new limit value or the action to take when the limit is exceeded, or both. sp_modify_resource_limit {name, appname } , rangename, limittype [, limitvalue] [, enforced] [, action] [, scope] 
sp_modify_time_range sp_modify_time_range - Changes the start day, start time, end day, and/or end time associated with a named time range. sp_modify_time_range name, startday, endday, starttime, endtime 
sp_modifylogin sp_modifylogin - Modifies the default database, default language, default role activation, or full name for a Adaptive Server login account. sp_modifylogin account, column, value 
sp_modifythreshold sp_modifythreshold - Modifies a threshold by associating it with a different threshold procedure, free-space level, or segment name. You cannot use sp_modifythreshold to change the amount of free space or the segment name for the last-chance threshold. sp_modifythreshold dbname, segname, free_space [, new_proc_name] [, new_free_space] [, new_segname] 
sp_monitor sp_monitor - Displays statistics about Adaptive Server. sp_monitor 
sp_monitorconfig sp_monitorconfig - Displays cache usage statistics regarding metadata descriptors for indexes, objects, and databases. sp_monitorconfig also reports statistics on auxiliary scan descriptors used for referential integrity queries. sp_monitorconfig "configname" 
sp_object_stats sp_object_stats - Prints lock statistics for tables and indexes. sp_object_stats interval [, top_n [, dbname, objname [, rpt_option ]]] 
sp_passthru sp_passthru - Allows the user to pass a SQL command buffer to a remote server. [, arg1, arg2, ... argn] 
sp_password sp_password - Adds or changes a password for an Adaptive Server login account. sp_password caller_passwd, new_passwd [, loginame] 
sp_pkeys sp_pkeys - Returns information about primary key constraints created with the create table or alter table command for a single table. sp_pkeys table_name [, table_owner] [, table_qualifier] 
sp_placeobject sp_placeobject - Puts future space allocations for a table or index on a particular segment. sp_placeobject segname, objname 
sp_plan_dbccdb sp_plan_dbccdb - Recommends suitable sizes for new dbccdb and dbccalt databases, lists suitable devices for dbccdb and dbccalt, and suggests a cache size and a suitable number of worker processes for the target database. sp_plan_dbccdb [dbname] 
sp_poolconfig sp_poolconfig - Creates, drops, resizes, and provides information about memory pools within data caches. To create a memory pool in an existing cache, or to change pool size: sp_poolconfig cache_name [, "mem_size[P|K|M|G]", "config_poolK" [, "affected_poolK"]] To change a pool's wash size: sp_poolconfig cache_name, "io_size", "wash=size[P|K|M|G]" To change a pool's asynchronous prefetch percentage: sp_poolconfig cache_name, "io_size", "local async prefetch limit=percent" 
sp_primarykey sp_primarykey - Defines a primary key on a table or view. sp_primarykey tabname, col1 [, col2, col3, ..., col8] 
sp_processmail sp_processmail - Reads, processes, sends, and deletes messages in the Adaptive Server message inbox, using the xp_findnextmsg, xp_readmail, xp_sendmail, and xp_deletemail system extended stired procedures (ESPs). sp_processmail [subject] [, originator [, dbuser [, dbname [, filetype [, separator]]]]] 
sp_procqmode sp_procqmode - Displays the query processing mode of a stored procedure, view, or trigger. sp_procqmode [object_name [, detail]] 
sp_procxmode sp_procxmode - Displays or changes the transaction modes associated with stored procedures. sp_procxmode [procname [, tranmode]] 
sp_recompile sp_recompile - Causes each stored procedure and trigger that uses the named table to be recompiled the next time it runs. sp_recompile objname 
sp_remap sp_remap - Remaps a stored procedure, trigger, rule, default, or view from releases later than 4.8 and prior to 10.0 to be compatible with releases 10.0 and later. Use sp_remap on pre-existing objects that the upgrade procedure failed to remap. sp_remap objname 
sp_remoteoption sp_remoteoption - Displays or changes remote login options. sp_remoteoption [remoteserver [, loginame [, remotename [, optname [, optvalue]]]]] 
sp_remotesql sp_remotesql - Establishes a connection to a remote server, passes a query buffer to the remote server from the client, and relays the results back to the client. sp_remotesql server, query [, query2, ... , query254] 
sp_rename sp_rename - Changes the name of a user-created object or user-defined datatype in the current database. sp_rename objname, newname 
sp_renamedb sp_renamedb - Changes the name of a user database. sp_renamedb dbname, newname 
sp_reportstats sp_reportstats - Reports statistics on system usage. sp_reportstats [loginame] 
sp_revokelogin sp_revokelogin - Revokes Adaptive Server roles and default permissions from Windows NT users and groups when Integrated Security mode or Mixed mode (with Named Pipes) is active. sp_revokelogin {login_name | group_name} 
sp_role sp_role - Grants or revokes system roles to an Adaptive Server login account. sp_role {"grant" | "revoke"}, {sa_role | sso_role | oper_role}, loginame 
sp_server_info sp_server_info - Returns a list of Adaptive Server attribute names and current values. sp_server_info [attribute_id] 
sp_serveroption sp_serveroption - Displays or changes remote server options. sp_serveroption [server, optname, optvalue] 
sp_setlangalias sp_setlangalias - Assigns or changes the alias for an alternate language. sp_setlangalias language, alias 
sp_setpglockpromote sp_setpglockpromote - Sets or changes the lock promotion thresholds for a database, for a table, or for Adaptive Server. sp_setpglockpromote {"database" | "table"}, objname, new_lwm, new_hwm, new_pct sp_setpglockpromote server, NULL, new_lwm, new_hwm, new_pct 
sp_setpsexe sp_setpsexe - Sets custom execution attributes "on the fly" for a session. sp_setpsexe spid, exeattr, value 
sp_setrowlockpromote tables on a server. new_hwm, new_pct new_lwm, new_hwm, new_pct 
sp_setsuspect_granularity sp_setsuspect_granularity - Displays or sets the recovery fault isolation mode for a user database, which governs how recovery behaves when it detects data corruption. sp_setsuspect_granularity [dbname [,{"database" | "page"} [, "read_only"]]] 
sp_setsuspect_threshold sp_setsuspect_threshold - Displays or sets the maximum number of suspect pages that Adaptive Server allows in a database before marking the entire database suspect. sp_setsuspect_threshold [dbname [, threshold]] 
sp_showcontrolinfo sp_showcontrolinfo - Displays information about engine group assignments, bound client applications, logins, and stored procedures. sp_showcontrolinfo [object_type, object_name, spid] 
sp_showexeclass sp_showexeclass - Displays the execution class attributes and the engines in any engine group associated with the specified execution class. sp_showexeclass [execlassname] 
sp_showplan sp_showplan - Displays the showplan output for any user connection for the current SQL statement or for a previous statement in the same batch. sp_showplan spid, batch_id output, context_id output, stmt_num output To display the showplan output for the current SQL statement without specifying the batch_id, context_id, or stmt_num: sp_showplan spid, null, null, null 
sp_showpsexe sp_showpsexe - Displays execution class, current priority, and affinity for all client sessions running on Adaptive Server. sp_showpsexe [spid] 
sp_spaceused number of data pages, the size of indexes, and the space used by a specified table or by all tables in the current database. sp_spaceused [objname [,1] ] 
sp_special_columns sp_special_columns - Returns the optimal set of columns that uniquely return a list of timestamp columns, whose values are automatically generated when any value in the sp_special_columns table_name [, table_owner] [, table_qualifier] [, col_type] 
sp_sproc_columns sp_sproc_columns - Returns information about a stored procedure's input and return parameters. sp_sproc_columns procedure_name [, procedure_owner] [, procedure_qualifier] [, column_name] 
sp_statistics sp_statistics - Returns a list of indexes on a single table. sp_statistics table_name [, table_owner] [, table_qualifier] [, index_name] [, is_unique] 
sp_stored_procedures sp_stored_procedures - Returns information about one or more stored procedures. sp_stored_procedures [sp_name [, sp_owner [, sp_qualifier]]] 
sp_syntax system procedures, utilities, and other routines for Adaptive Server, depending on which products and corresponding sp_syntax scripts exist on your server. sp_syntax word [, mod][, language] 
sp_sysmon sp_sysmon - Displays performance information. sp_sysmon { begin_sample | end_sample | interval } [, section] 
sp_table_privileges sp_table_privileges - Returns privilege information for all columns in a table or view. sp_table_privileges table_name [, table_owner [, table_qualifier]] 
sp_tables sp_tables - Returns a list of objects that can appear in a from clause. sp_tables [table_name] [, table_owner] [, table_qualifier][, table_type] 
sp_thresholdaction sp_thresholdaction - Executes automatically when the number of free pages on the log segment falls below the last-chance threshold, unless the threshold is associated with a different procedure. Sybase does not provide this procedure. When a threshold is crossed, Adaptive Server passes the following parameters to the threshold procedure by position: sp_thresholdaction @dbname, @segment_name, @space_left, @status 
sp_unbindcache sp_unbindcache - Unbinds a database, table, index, text object, or image object from a data cache. sp_unbindcache dbname [,[owner.]tablename [, indexname | "text only"]] 
sp_unbindcache_all sp_unbindcache_all - Unbinds all objects that are bound to a cache. sp_unbindcache_all cache_name 
sp_unbindefault sp_unbindefault - Unbinds a created default value from a column or from a user-defined datatype. sp_unbindefault objname [, futureonly] 
sp_unbindexeclass sp_unbindexeclass - Removes the execution class attribute previously associated with an client application, login, or stored procedure for the specified scope. sp_unbindexeclass object_name, object_type, scope 
sp_unbindmsg sp_unbindmsg - Unbinds a user-defined message from a constraint. sp_unbindmsg constrname 
sp_unbindrule sp_unbindrule - Unbinds a rule from a column or from a user-defined datatype. sp_unbindrule objname [, futureonly] 
sp_volchanged sp_volchanged - Notifies the Backup Server that the operator performed the requested volume handling during a dump or load. sp_volchanged session_id, devname, action [, fname [, vname]] 
sp_who sp_who - Reports information about all current Adaptive Server users and processes or about a particular user or process. sp_who [loginame | "spid"] 

 

共享共进共赢Sharing And Win-win Results
ehxz

主题

0

回帖

59万

积分

管理员

积分
590891
贡献
在线时间
小时
2008-2-21 11:06:07 | 显示全部楼层

Quick Reference Guide for ASE


 

Transac SQL statments
 

abs abs - Returns the absolute value of an expression. abs(numeric_expression) 
acos acos - Returns the angle (in radians) whose cosine is specified. acos(cosine) 
alter database 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] 
alter role alter role - Defines mutually exclusive relationships between roles and adds, drops, and changes passwords for roles. alter role role1 { add | drop } exclusive { membership | activation } role2 alter role role_name { add passwd "password"| drop passwd } 
alter table alter table - Changes the locking scheme for an existing table; specifies ascending or descending index order when alter table is used to create referential integrity constraints that are based on indexes; specifies the ratio of filled pages to empty pages, to reduce storage fragmentation. alter table [database.[owner].]table_name { add column_name datatype [default {constant_expression | user | null}] {identity | null} [ [constraint constraint_name] { { unique | primary key } [clustered | nonclustered] [asc | desc] [with { { fillfactor = pct , reservepagegap = num_pages }] [on segment_name] | references [[database.]owner.]ref_table [(ref_column)] | check (search_condition) ] ... } [, next_column]... | add { [constraint constraint_name] { {unique | primary key} [clustered | nonclustered] (column_name [asc | desc] [, column_name [asc | desc]...]) [with { { fillfactor = pct , reservepagegap = num_pages}] [on segment_name] | foreign key (column_name [,column_name...]) references [[database.]owner.]ref_table [(ref_column [, ref_column...])] | check (search_condition)} } | drop constraint constraint_name | replace column_name default {constant_expression | user | null} | partition number_of_partitions | unpartition 
ascii ascii - Returns the ASCII code for the first character in an expression. ascii(char_expr) 
asin asin - Returns the angle (in radians) whose sine is specified. asin(sine) 
atan atan - Returns the angle (in radians) whose tangent is specified. atan(tangent) 
atn2 atn2 - Returns the angle (in radians) whose sine and cosine are specified. atn2(sine, cosine) 
avg avg - Returns the numeric average of all (distinct) values. avg([all | distinct] expression) 
begin transaction begin transaction - Marks the starting point of a user-defined transaction. begin tran[saction] [transaction_name] 
begin...end begin...end - Encloses a series of SQL statements so that control-of-flow language, such as if...else, can affect the performance of the whole group. begin statement block end 
break break - Causes an exit from a while loop. break is often activated by an if test. while logical_expression statement break statement continue 
case case - Supports conditional SQL expressions. case expressions can be used anywhere a value expression can be used. case when search_condition then expression [when search_condition then expression]... [else expression] end case expression when expression then expression [when expression then expression]... [else expression] end coalesce(expression, expression [, expression]...) nullif(expression, expression) 
ceiling ceiling - Returns the smallest integer greater than or equal to the specified value. ceiling(value) 
char char - Returns the character equivalent of an integer. char(integer_expr) 
char_length char_length - Returns the number of characters in an expression. char_length(char_expr) 
charindex charindex - Returns an integer representing the starting position of an expression. charindex(expression1, expression2) 
checkpoint checkpoint - Writes all dirty pages (pages that have been updated since they were last written) to the database device. checkpoint 
close close - Deactivates a cursor. close cursor_name 
col_length col_length - Returns the defined length of a column. col_length(object_name, column_name) 
col_name col_name - Returns the name of the column whose table and column IDs are specified. col_name(object_id, column_id[, database_id]) 
commit commit - Marks the ending point of a user-defined transaction. commit [tran[saction] | work] [transaction_name] 
compare compare - Compares two character strings based on alternate collation rules. compare (char_expression1, char_expression2 [, {collation_name | collation_ID}]) 
compute Clause compute Clause - Generates summary values that appear as start_of_select_statement [by column_name [, column_name]...] 
connect to...disconnect connect to...disconnect - Connects to the specified server and disconnects the connected server. connect to server_name disconnect 
continue continue - Restarts the while loop. continue is often activated by an if test. while boolean_expression statement break statement continue 
convert convert - Returns the specified value, converted to another datatype or a different datetime display format. convert (datatype [(length) | (precision[, scale])], expression[, style]) 
cos cos - Returns the cosine of the specified angle. cos(angle) 
cot cot - Returns the cotangent of the specified angle. cot(angle) 
count count - Returns the number of (distinct) non-null values count([all | distinct] expression) 
create database create database - Creates a new database. Use create database from the master database. create database database_name [on {default | database_device} [= size] [, database_device [= size]]...] [log on database_device [= size] [, database_device [= size]]...] [with override] [for load] 
create default create default - Specifies a value to insert in a column (or in all columns of a user- defined datatype) if no value is explicitly supplied at insert time. create default [owner.]default_name as constant_expression 
create existing table create existing table - Allows you to map the proxy table to a table, view, or procedure at a remote location. create existing table table_name (column_list) [ on segment_name ] [ [ external {table | procedure} ] at pathname ] 
create index create index - Creates an index in ascending or descending order for each column; allows up to 31 columns per index; leaves a specified number of unused pages during index creation; allows specification of the number of steps in the distribution histogram for the index. create [unique] [clustered | nonclustered] index index_name on [[database.]owner.]table_name (column_name [asc | desc] [, column_name [asc | desc]]...) [with { reservepagegap = num_pages, consumers = x, ignore_dup_key, sorted_data, , statistics using num_steps values } ] [on segment_name] 
create procedure create procedure - Creates a stored procedure or an extended stored procedure (ESP) that can take one or more user-supplied parameters. create procedure [owner.]procedure_name[;number] [[(]@parameter_name datatype [(length) | (precision [, scale])] [= default][output] [, @parameter_name datatype [(length) | (precision [, scale])] [= default][output]]...[)]] [with recompile] as {SQL_statements | external name dll_name} 
create proxy_table create proxy_table - Creates a proxy table without specifying a column list. CIS derives the column list from the metadata it obtains from the remote table. create proxy_table table_name [ external table ] at pathname 
create role create role - Creates a user-defined role. create role role_name [with passwd "password"] 
create rule create rule - Specifies the domain of acceptable values for a particular column or for any column of a user-defined datatype. create rule [owner.]rule_name as condition_expression 
create schema create schema - Creates a new collection of tables, views, and permissions for a database user. create schema authorization authorization_name create_oject_statement [ create_object_statement ... ] [ permission_statement ... ] 
create table create table - Specifies a locking scheme for the table being created; specifies ascending or descending index order when creating referential integrity constraints that depend on indexes; specifies the specifies a ratio of empty pages to be left for each filled page. create table [database.[owner].]table_name (column_name datatype [default {constant_expression | user | null}] {[{identity | null | not null}] | [[constraint constraint_name] {{unique | primary key} [clustered | nonclustered] [asc | desc] [with { { fillfactor = pct , reservepagegap = num_pages }] [on segment_name] | references [[database.]owner.]ref_table [(ref_column)] | check (search_condition)}]}... | [constraint constraint_name] {{unique | primary key} [clustered | nonclustered] (column_name [asc | desc] [{, column_name [asc | desc]}...]) [with { {fillfactor = pct reservepagegap = num_pages } ] [on segment_name] |foreign key (column_name [{, column_name}...]) references [[database.]owner.]ref_table [(ref_column [{, ref_column}...])] | check (search_condition) ... } [{, {next_column | next_constraint}}...]) reservepagegap = num_pages } ] [on segment_name] [ [ external table ] at pathname ] 
create trigger create trigger - Creates a trigger, a type of stored procedure that is often used for enforcing integrity constraints. A trigger executes automatically when a user attempts a specified data modification statement on a specified table. create trigger [owner.]trigger_name on [owner.]table_name for {insert , update , delete} as SQL_statements Or, using the if update clause: create trigger [owner.]trigger_name on [owner.]table_name for {insert , update} as [if update (column_name) [{and | or} update (column_name)]...] SQL_statements [if update (column_name) [{and | or} update (column_name)]... SQL_statements]... 
create view create view - Creates a view, which is an alternative way of looking at the data in one or more tables. create view [owner.]view_name [(column_name [, column_name]...)] as select [distinct] select_statement [with check option] 
curunreservedpgs curunreservedpgs - Returns the number of free pages in the specified disk piece. curunreservedpgs(dbid, lstart, unreservedpgs) 
data_pgs data_pgs - Returns the number of pages used by the specified table or index. data_pgs(object_id, {data_oam_pg_id | index_oam_pg_id}) 
datalength datalength - Returns the actual length, in bytes, of the specified column or string. datalength(expression) 
dateadd dateadd - Returns the date produced by adding a given number of years, quarters, hours, or other date parts to the specified date. dateadd(date_part, integer, date) 
datediff datediff - Returns the difference between two dates. datediff(datepart, date1, date2) 
datename datename - Returns the name of the specified part of a datetime value. datename (datepart, date) 
datepart datepart - Returns the integer value of the specified part of a datetime value. datepart(date_part, date) 
db_id db_id - Returns the ID number of the specified database. db_id(database_name) 
db_name db_name - Returns the name of the database whose ID number is specified. db_name([database_id]) 
dbcc dbcc - Database Consistency Checker (dbcc) checks the logical and physical consistency of a database. Use dbcc regularly as a periodic check or if you suspect any damage. dbcc checkalloc [(database_name [, fix | nofix])] dbcc checkcatalog [(database_name)] dbcc checkdb [(database_name [, skip_ncindex])] dbcc checkstorage [(database_name)] dbcc checktable({table_name|table_id}[, skip_ncindex]) dbcc checkverify(dbname) dbcc dbrepair (database_name, dropdb) dbcc fix_text ({table_name | table_id}) dbcc indexalloc ({table_name | table_id}, index_id [, {full | optimized | fast | null} [, fix | nofix]]) dbcc reindex ({table_name | table_id}) dbcc tablealloc ({table_name | table_id} [, {full | optimized | fast | null} [, fix | nofix]])| dbcc { traceon | traceoff } (3604,302) dbcc tune ( { ascinserts, {0 | 1 } , tablename | cleanup, {0 | 1 } | cpuaffinity, start_cpu [, on| off] | deviochar vdevno, "batch_size" | doneinproc { 0 | 1 } | maxwritedes, writes_per_batch } ) 
deallocate cursor deallocate cursor - Makes a cursor inaccessible and releases all memory resources committed to that cursor. deallocate cursor cursor_name 
declare declare - Declares the name and type of local variables for a batch or procedure. Variable declaration: declare @variable_name datatype [, @variable_name datatype]... Variable assignment: select @variable = {expression | select_statement} [, @variable = {expression | select_statement} ...] [from table_list] [where search_conditions] [group by group_by_list] [having search_conditions] [order by order_by_list] [compute function_list [by by_list]] 
declare cursor declare cursor - Defines a cursor. declare cursor_name cursor for select_statement [for {read only | update [of column_name_list]}] 
degrees degrees - Returns the size, in degrees, of an angle with the specified number of radians. degrees(numeric) 
delete delete - The readpast clause allows the delete command to delete [[database.]owner.]{table_name | view_name} [from [[database.]owner.]{view_name [readpast]| table_name [readpast] [(index {index_name | table_name } [ prefetch size ][lru|mru])]} [, [[database.]owner.]{view_name [readpast]| table_name [readpast] [(index {index_name | table_name } [ prefetch size ][lru|mru])]} ...] [where search_conditions] ] 
delete statistics delete statistics - Removes statistics from the sysstatistics system table. delete statistics table_name [(column_name [,...])] 
difference difference - Returns the difference between two soundex values. difference(char_expr1, char_expr2) 
disk init disk init - Makes a physical device or file usable by Adaptive Server. disk init 1name = "device_name" , physname = "physicalname" , vdevno = virtual_device_number , size = number_of_blocks [, vstart = virtual_address , cntrltype = controller_number ] [, contiguous] 
disk mirror disk mirror - Creates a software mirror that immediately takes over when the primary device fails. disk mirror name = "device_name" , mirror = "physicalname" [ ,writes = { serial | noserial }] [ ,contiguous ] (OpenVMS only) 
disk refit disk refit - Rebuilds the master database's sysusages and sysdatabases system tables from information contained in sysdevices. disk refit 
disk reinit disk reinit - Rebuilds the master database's sysdevices system table. Use disk reinit as part of the procedure to restore the master database. disk reinit name = "device_name", physname = "physicalname" , vdevno = virtual_device_number , size = number_of_blocks [, vstart = virtual_address , cntrltype = controller_number] 
disk remirror disk remirror - Restarts disk mirroring after it is stopped by failure of a mirrored device or temporarily disabled by the disk unmirror command. disk remirror name = "device_name" 
disk unmirror disk unmirror - Suspends disk mirroring initiated with the disk mirror command to allow hardware maintenance or the changing of a hardware device. disk unmirror name = "device_name" [ ,side = { "primary" | secondary }] [ ,mode = { retain | remove }] 
drop database drop database - Removes one or more databases from Adaptive Server. drop database database_name [, database_name]... 
drop default drop default - Removes a user-defined default. drop default [owner.]default_name [, [owner.]default_name]... 
drop index drop index - Removes an index from a table in the current database. drop index table_name.index_name [, table_name.index_name]... 
drop procedure drop procedure - Removes a procedure. drop proc[edure] [owner.]procedure_name [, [owner.]procedure_name] ... 
drop role drop role - Drops a user-defined role. drop role role_name [with override] 
drop rule drop rule - Removes a user-defined rule. drop rule [owner.]rule_name [, [owner.]rule_name]... 
drop table drop table - Removes a table definition and all of its data, indexes, triggers, and permissions from the database. drop table [[database.]owner.]table_name [, [[database.]owner.]table_name ]... 
drop trigger drop trigger - Removes a trigger. drop trigger [owner.]trigger_name [, [owner.]trigger_name]... 
drop view drop view - Removes one or more views from the current database. drop view [owner.]view_name [, [owner.]view_name]... 
dump database dump database - Makes a backup copy of the entire database, including the transaction log, in a form that can be read in with load database. Dumps and loads are performed through Backup Server. dump database database_name to stripe_device [ at backup_server_name ] [density = density_value, blocksize = number_bytes, capacity = number_kilobytes, dumpvolume = volume_name, file = file_name] [stripe on stripe_device [ at backup_server_name ] [density = density_value, blocksize = number_bytes, capacity = number_kilobytes, dumpvolume = volume_name, file = file_name]] [[stripe on stripe_device [ at backup_server_name ] [density = density_value, blocksize = number_bytes, capacity = number_kilobytes, dumpvolume = volume_name, file = file_name]]...] [with { density = density_value, blocksize = number_bytes, capacity = number_kilobytes, dumpvolume = volume_name, file = file_name, [dismount | nodismount], [nounload | unload], retaindays = number_days, [noinit | init], notify = {client | operator_console} }] 
dump transaction dump transaction - Dumps only completed transactions. To make a routine or standby access log dump: dump tran[saction] database_name to stripe_device [ at backup_server_name ] [density = density_value, blocksize = number_bytes, capacity = number_kilobytes, dumpvolume = volume_name, file = file_name] [stripe on stripe_device [ at backup_server_name ] [density = density_value, blocksize = number_bytes, capacity = number_kilobytes, dumpvolume = volume_name, file = file_name]] [[stripe on stripe_device [ at backup_server_name ] [density = density_value, blocksize = number_bytes, capacity = number_kilobytes, dumpvolume = volume_name, file = file_name] ]...] [with { density = density_value, blocksize = number_bytes, capacity = number_kilobytes, dumpvolume = volume_name, file = file_name, [dismount | nodismount], [nounload | unload], retaindays = number_days, [noinit | init], notify = {client | operator_console} standby_access }] To truncate the log without making a backup copy: dump tran[saction] database_name with truncate_only To truncate a log that is filled to capacity.Use only as a last resort dump tran[saction] database_name with no_log To back up the log after a database device fails: dump tran[saction] database_name to stripe_device [ at backup_server_name ] [density = density_value, blocksize = number_bytes, capacity = number_kilobytes, dumpvolume = volume_name, file = file_name] [stripe on stripe_device [ at backup_server_name ] [density = density_value, blocksize = number_bytes, capacity = number_kilobytes, dumpvolume = volume_name, file = file_name]] [[stripe on stripe_device [ at backup_server_name ] [density = density_value, blocksize = number_bytes, capacity = number_kilobytes, dumpvolume = volume_name, file = file_name] ]...] [with { density = density_value, blocksize = number_bytes, capacity = number_kilobytes, dumpvolume = volume_name, file = file_name, [dismount | nodismount], [nounload | unload], retaindays = number_days, [noinit | init], no_truncate, notify = {client | operator_console}}] 
execute execute - Runs a procedure. [exec[ute]] [@return_status = ] [[[server.]database.]owner.]procedure_name[;number] [[@parameter_name =] value | [@parameter_name =] @variable [output] [,[@parameter_name =] value | [@parameter_name =] @variable [output]...]] [with recompile] 
exp exp - Returns the value that results from raising the constant e to the specified power. exp(approx_numeric) 
fetch result set. fetch cursor_name [ into fetch_target_list ] 
floor floor - Returns the largest integer that is less than or equal to the specified value. floor(numeric) 
getdate getdate - Returns the current system date and time. getdate() 
goto Label goto Label - Branches to a user-defined label. label: goto label 
grant grant - Assigns permissions to users or to user-defined roles. To grant permission to access database objects: grant {all [privileges]| permission_list} on { table_name [(column_list)] | view_name[(column_list)] | stored_procedure_name} to {public | name_list | role_name} [with grant option] To grant permission to execute certain commands: grant {all [privileges] | command_list} to {public | name_list | role_name} To grant a role to a user or a role: grant {role role_granted [, role_granted ...]} to grantee [, grantee...] 
group by and having group by and having - Used in select statements to divide a table into groups and to return only groups that match conditions in the having clause. Start of select statement [group by [all] aggregate_free_expression [, aggregate_free_expression]...] [having search_conditions] End of select statement 
hextoint hextoint - Returns the platform-independent integer equivalent of a hexadecimal string. hextoint (hexadecimal_string) 
host_id host_id - Returns the host process ID or the client process. host_id() 
host_name host_name - Returns the current host computer name of the client process. host_name() 
if...else if...else - Imposes conditions on the execution of a SQL statement. if logical_expression statements [else [if logical_expression] statement] 
index_col index_col - Returns the name of the indexed column in the specified table or view. index_col (object_name, index_id, key_# [, user_id]) 
index_colorder index_colorder - Returns the column order. index_colorder (object_name, index_id, key_# [, user_id]) 
insert insert [into] [database.[owner.]]{table_name|view_name} [(column_list)] {values (expression [, expression]...) |select_statement } 
inttohex inttohex - Returns the platform-independent hexadecimal equivalent of the specified integer. inttohex (integer_expression) 
is_sec_service_on is_sec_service_on - Returns 1 if the security service is active and 0 if it is not. is_sec_service_on(security_service_nm) 
isnull isnull - Substitutes the value specified in expression2 when expression1 evaluates to NULL. isnull(expression1, expression2) 
kill kill - Kills a process. kill spid 
lct_admin lct_admin - Returns the current value of the last-chance threshold. Aborts transactions in a transaction log that has reached its last-chance threshold. lct_admin({{"lastchance" | "logfull" }, database_id |"reserve", {log_pages | 0 } | "abort", process-id [, database-id]}) 
load database load database - Loads a backup copy of a user database, including its transaction log, that was created with dump database. load database database_name from stripe_device [at backup_server_name ] [density = density_value, blocksize = number_bytes, dumpvolume = volume_name, file = file_name] [stripe on stripe_device [at backup_server_name ] [density = density_value, blocksize = number_bytes, dumpvolume = volume_name, file = file_name] [[stripe on stripe_device [at backup_server_name ] [density = density_value, blocksize = number_bytes, dumpvolume = volume_name, file = file_name]]...] [with { density = density_value, blocksize = number_bytes, dumpvolume = volume_name, file = file_name, [dismount | nodismount], [nounload | unload], listonly [= full], headeronly, notify = {client | operator_console} }]] 
load transaction load transaction - Loads a backup copy of the transaction log that was created with the dump transaction command. load tran[saction] database_name from stripe_device [at backup_server_name] [density = density_value, blocksize = number_bytes, dumpvolume = volume_name, file = file_name] [stripe on stripe_device [at backup_server_name] [density = density_value, blocksize = number_bytes, dumpvolume = volume_name, file = file_name] [[stripe on stripe_device [at backup_server_name] [density = density_value, blocksize = number_bytes, dumpvolume = volume_name, file = file_name]]...] [with { density = density_value, blocksize = number_bytes, dumpvolume = volume_name, file = file_name, [dismount | nodismount], [nounload | unload], listonly [= full], headeronly, notify = {client | operator_console} until_time = datetime}]] 
lock table lock table - Explicitly locks a table within a transaction. lock table table_name in {share | exclusive } mode [ wait [ numsecs ] | nowait ] 
log log - Returns the natural logarithm of the specified number. log(approx_numeric) 
log10 log10 - Returns the base 10 logarithm of the specified number. log10(approx_numeric) 
lower lower - Returns the lowercase equivalent of the specified expression. lower(char_expr) 
ltrim ltrim - Returns the specified expression, trimmed of leading blanks. ltrim(char_expr) 
max max - Returns the highest value in an expression. max(expression) 
min min - Returns the lowest value in a column. min(expression) 
mut_excl_roles mut_excl_roles - Returns information about the mutual exclusivity between two roles. mut_excl_roles ("role1", "role2" ["membership" | "activation"]) 
object_id object_id - Returns the object ID of the specified object. object_id(object_name) 
object_name object_name - Returns the name of the object whose object ID is specified. object_name(object_id[, database_id]) 
online database online database - Brings a database online after loading a transaction log dumped with the standby_access option. online database database_name [for standby_access] 
open open - Opens a cursor for processing. open cursor_name 
order by Clause order by Clause - Returns query results in the specified column(s) in sorted order. [Start of select statement] [order by {[table_name.| view_name.]column_name | select_list_number | expression} [asc | desc] [,{[table_name.| view_name.] column_name select_list_number|expression} [asc |desc]]...] [End of select statement] 
patindex patindex - Returns the starting position of the first occurrence of a specified pattern. patindex("%pattern%", char_expr [, using {bytes | characters | chars} ] ) 
pi pi - Returns the constant value 3.1415926535897936. pi() 
power power - Returns the value that results from raising the specified number to a given power. power(value, power) 
prepare transaction prepare transaction - Used by DB-Library in a two-phase commit application to see if a server is prepared to commit a transaction. prepare tran[saction] 
print print - Prints a user-defined message on the user's screen. print {format_string | @local_variable | @@global_variable} [, arg_list] 
proc_role proc_role - Returns 1 if the user has the correct role to execute the procedure; 0 if the user does not have this role. proc_role ("sa_role" | "sso_role" | "oper_role" | "replication_role" | "role_name" ) 
ptn_data_pgs ptn_data_pgs - Returns the number of data pages used by a partition. ptn_data_pgs(object_id, partition_id) 
radians radians - Returns the size, in radians, of an angle with the specified number of degrees. radians(numeric) 
raiserror raiserror - Prints a user-defined error message on the user's screen and sets a system flag to record that an error condition has occurred. raiserror error_number [{format_string | @local_variable}] [, arg_list] [with errordata restricted_select_list] 
rand rand - Returns a random value between 0 and 1, which is generated using the specified seed value. rand([integer]) 
readtext have exclusive locks on them, without waiting and without generating a message. readtext [[database.]owner.]table_name.column_name text_pointer offset size [holdlock | noholdlock] [shared] [readpast] [using {bytes | chars | characters}] [at isolation {read uncommitted | read committed | serializable}] 
reconfigure reconfigure - The reconfigure command currently has no effect; it is included to allow existing scripts to run without modification. In previous releases, reconfigure was required after the system procedure sp_configure to implement new configuration parameter settings. reconfigure 
reorg new pages, depending on the option used. reorg reclaim_space tablename [indexname] [with {resume, time = no_of_minutes}] [with {resume,time = no_of_minutes}] reorg compact tablename [with {resume, time = no_of_minutes}] reorg rebuild tablename 
replicate replicate - Returns a string consisting of the specified expression repeated a given number of times. replicate (char_expr, integer_expr) 
reserved_pgs reserved_pgs - Returns the number of pages allocated to the specified table or index. reserved_pgs(object_id, {doampg|ioampg}) 
return return - Exits from a batch or procedure unconditionally and provides an optional return status. Statements following return are not executed. return [integer_expression] 
reverse reverse - Returns the specified string with characters listed in reverse order. reverse(expression) 
revoke revoke - Revokes permissions or roles from users or roles. To revoke permission to access database objects: revoke [grant option for] {all [privileges] | permission_list} on { table_name [(column_list)] | view_name [(column_list)] | stored_procedure_name} from {public | name_list | role_name} [cascade] To revoke permission to create database objects, execute set proxy, or execute set session authorization: revoke {all [privileges] | command_list} from {public | name_list | role_name} To revoke a role from a user or another role: revoke role {role_name [, role_name ...]} from {grantee [, grantee ...]} 
right right - The rightmost part of the expression with the specified number of characters. right(expression, integer_expr) 
role_contain role_contain - Returns 1 if role2 contains role1. role_contain("role1", "role2") 
role_id role_id - Returns the system role ID of the role whose name you specify. role_id("role_name") 
role_name role_name - Returns the name of a role whose system role ID you specify. role_name([role_id]) 
rollback rollback - Rolls back a user-defined transaction to the named savepoint in the transaction or to the beginning of the transaction. rollback {tran[saction] | work} [transaction_name | savepoint_name] 
rollback trigger rollback trigger - Rolls back the work done in a trigger, including the data modification that caused the trigger to fire, and issues an optional raiserror statement. rollback trigger [with raiserror_statement] 
round round - Returns the value of the specified number, rounded to a given number of decimal places. round(number, decimal_places) 
rowcnt specified table. 
rtrim rtrim - Returns the specified expression, trimmed of trailing blanks. rtrim(char_expr) 
save transaction save transaction - Sets a savepoint within a transaction. save transaction savepoint_name 
select select - Allows specifying the locking scheme with select have exclusive locks on them without waiting and without generating a message. select [all | distinct] select_list [into [[database.]owner.]table_name reservepagegap = num_pages } ] ] [from [[database.]owner.]{view_name|table_name [(index {index_name | table_name } [parallel [degree_of_parallelism]] [prefetch size ][lru|mru])]} [holdlock | noholdlock] [readpast] [shared] [,[[database.]owner.]{view_name|table_name [(index {index_name | table_name } [parallel [degree_of_parallelism]] [prefetch size ][lru|mru])]} [holdlock | noholdlock] [readpast] [shared]]...] [where search_conditions] [group by [all] aggregate_free_expression [, aggregate_free_expression]... ] [having search_conditions] [order by {[[[database.]owner.]{table_name.|view_name.}] column_name | select_list_number | expression} [asc | desc] [,{[[[database.]owner.]{table_name|view_name.}] column_name | select_list_number | expression} [asc | desc]]...] [by column_name [, column_name]...]] [for {read only | update [of column_name_list]}] [at isolation { [ read uncommitted | 0 ] | [ read committed | 1 ] | [ repeatable read | 2 ]| [ serializable | 3 ] } ] 
set set - Sets Adaptive Server query-processing options for the duration of the user's work session. Can be used to set some options inside a trigger or stored procedure. Can also be used to activate or deactivate a role in the current session. set ansinull {on | off} set ansi_permissions {on | off} set arithabort [arith_overflow | numeric_truncation] {on | off} set arithignore [arith_overflow] {on | off} set {chained, close on endtran, nocount, noexec, parseonly, procid, self_recursion, showplan, sort_resources} {on | off} set char_convert {off | on [with {error | no_error}] | charset [with {error | no_error}]} set cis_rpc_handling {on | off} set {datefirst number, dateformat format, language language} set fipsflagger {on | off} set flushmessage {on | off} set identity_insert [database.[owner.]]table_name {on | off} set lock { wait [ numsecs ] | nowait } set offsets {select, from, order, compute, table, procedure, statement, param, execute} {on | off} set parallel_degree number set prefetch [on|off] set process_limit_action {abort | quiet | warning} set proxy [login_name] set quoted_identifier {on | off} set role {"sa_role" | "sso_role" | "oper_role" | role_name [with passwd "password"]} {on | off} set scan_parallel_degree number set session authorization [login_name] set showplan {on | off} set sort_resources {on | off} set statistics {io, subquerycache, time} {on | off} set string_rtruncation {on | off} set table count number set textsize {number} set transaction isolation level { [ read uncommitted | 0 ] | [ read committed | 1 ] | [ repeatable read | 2 ]| [ serializable | 3 ] } set transactional_rpc {on | off} 
setuser setuser - Allows a Database Owner to impersonate another user. setuser ["user_name"] 
show_role show_role - Shows the login's currently active system-defined roles. show_role() 
show_sec_services show_sec_services - Lists the security services that are active for the session. show_sec_services() 
shutdown shutdown - Shuts down the Adaptive Server from which the command is issued, its local Backup Server, or a remote Backup Server. This command can be issued only by a System Administrator. shutdown [srvname] [with {wait | nowait}] 
sign sign - Returns the sign (+1 for positive, 0, or -1 for negative) of the specified value. sign(numeric) 
sin sin - Returns the sine of the specified angle (in radians). sin(approx_numeric) 
sortkey sortkey - Generates values that can be used to order results based on collation behavior. sortkey (char_expression [, {collation_name | collation_ID}]) 
soundex soundex - Returns a 4-character code representing the way an expression sounds. soundex(char_expr) 
space space - Returns a string consisting of the specified number of single-byte spaces. space(integer_expr) 
sqrt sqrt - Returns the square root of the specified number. sqrt(approx_numeric) 
str str - Returns the character equivalent of the specified number. str(approx_numeric [, length [, decimal] ]) 
stuff stuff - Returns the string formed by deleting a specified number of characters from one string and replacing them with another string. stuff(char_expr1, start, length, char_expr2) 
substring substring - Returns the string formed by extracting the specified number of characters from another string. substring(expression, start, length) 
sum sum - Returns the total of the values. sum([all | distinct] expression) 
suser_id suser_id - Returns the server user's ID number from the syslogins table. suser_id([server_user_name]) 
suser_name suser_name - Returns the name of the current server user or the user whose server ID is specified. suser_name([server_user_id]) 
tan tan - Returns the tangent of the specified angle (in radians). tan(angle) 
textptr textptr - Returns the 16-byte binary pointer to the first page of the specified text column. textptr(column_name) 
textvalid textvalid - Returns 1 if the pointer to the specified text column is valid; 0 if it is not. textvalid("table_name.column_name", textpointer) 
truncate table truncate table [[database.]owner.]table_name 
tsequal tsequal - Compares timestamp values to prevent update on a 
union Operator union Operator - Returns a single result set that combines the are eliminated from the result set unless the all keyword is specified. select select_list [into clause] [from clause] [where clause] [group by clause] [having clause] [union [all] select select_list [from clause] [where clause] [group by clause] [having clause] ]... [order by clause] [compute clause] 
update update - The readpast clause allows the update command to update [[database.]owner.]{table_name | view_name} set [[[database.]owner.]{table_name.|view_name.}] column_name1 = {expression1|NULL|(select_statement)} | variable_name1 = {expression1|NULL|(select_statement)} [, column_name2 = {expression2|NULL|(select_statement)}]... | [, variable_name2 = {expression2|NULL|(select_statement)}]... [from [[database.]owner.]{view_name [readpast]| table_name [readpast] [(index {index_name | table_name } [ prefetch size ][lru|mru])]} [,[[database.]owner.]{view_name [readpast]| table_name [readpast] [(index {index_name | table_name } [ prefetch size ][lru|mru])]}] ...] [where search_conditions] 
update partition statistics update partition statistics - Updates information about the number of pages each partition for a partitioned table. update partition statistics table_name [partition_number] 
update statistics update statistics - Updates information about the distribution of key values in specified indexes or for specified columns, for all columns in an index, or for all columns on a table; allows specifying the number of steps for a histogram. update statistics table_name [ [index_name] | [( column_list ) ] ] [using step values] [with consumers = consumers ] update all statistics table_name update index statistics table_name [index_name] [using step values] [with consumers = consumers ] 
upper upper - Returns the uppercase equivalent of the specified string. upper(char_expr) 
use use - Specifies the database with which you want to work. use database_name 
used_pgs used_pgs - Returns the number of pages used by the specified table and its clustered index, or the number of pages in a nonclustered index. used_pgs(object_id, doampg, ioampg) 
user user - Returns the name of the current user. user 
user_id user_id - Returns the ID number of the specified user or of the current user in the database. user_id([user_name]) 
user_name user_name - Returns the name within the database of the specified user or of the current user. user_name([user_id]) 
valid_name valid_name - Returns 0 if the specified string is not a valid identifier or a number other than 0 if the string is a valid identifier. valid_name(character_expression) 
valid_user valid_user - Returns 1 if the specified ID is a valid user or alias in at least one database on this Adaptive Server. valid_user(server_user_id) 
waitfor waitfor - Specifies a specific time, a time interval, or an event for the execution of a statement block, stored procedure, or transaction. waitfor { delay time | time time | errorexit | processexit | mirrorexit } 
where Clause where Clause - Sets the search conditions in a select, insert, update, or delete statement. Search conditions immediately follow the keyword where in a select, insert, update, or delete statement. If you use more than one search condition in a single statement, connect the conditions with and or or where [not] expression comparison_operator expression where [not] expression [not] like "match_string" [escape "escape_character"] where [not] expression is [not] null where [not] expression [not] between expression and expression where [not] expression [not] in ({value_list | subquery}) where [not] exists (subquery) where [not] expression comparison_operator {any | all} (subquery) where [not] column_name join_operator column_name where [not] logical_expression where [not] expression {and | or} [not] expression 
while while - Sets a condition for the repeated execution of a statement or statement block. The statement(s) are executed repeatedly, as long as the specified condition is true. while logical_expression statement 
writetext writetext [[database.]owner.]table_name.column_name text_pointer [readpast] [with log] data 

共享共进共赢Sharing And Win-win Results
JohnPhan 楼主

主题

0

回帖

228

积分

注册会员

积分
228
贡献
在线时间
小时
2008-2-27 10:31:27 | 显示全部楼层

官方的ASE Quick Reference Guide

另一个版本的ASE Quick Reference Guide。官方的。 zkMa9lwR.rar (192.89 KB, 下载次数: 5)
共享共进共赢Sharing And Win-win Results
您需要登录后才可以回帖 登录 | 站点注册

本版积分规则

免责声明:
本站所发布的一切破解补丁、注册机和注册信息及软件的解密分析文章仅限用于学习和研究目的;不得将上述内容用于商业或者非法用途,否则,一切后果请用户自负。本站信息来自网络,版权争议与本站无关。您必须在下载后的24个小时之内,从您的电脑中彻底删除上述内容。如果您喜欢该程序,请支持正版软件,购买注册,得到更好的正版服务。如有侵权请邮件与我们联系处理。

Mail To:Admin@SybaseBbs.com

QQ|Archiver|PowerBuilder(PB)BBS社区 ( 鲁ICP备2021027222号-1 )

GMT+8, 2024-12-23 06:09 , Processed in 0.043761 second(s), 8 queries , MemCached On.

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表