附录A. 关键字和保留字

神通数据库有一些保留字。它们对于神通数据库有特殊的意义,不可以被用户重定义。因为这个原因,用户不能使用它们来命名数据库对象,比如列、表或者索引。详细的保留字表参见《神通数据库SQL语言手册》。

和C或者C++关键字一样,esql*C的关键字不应该作为应用程序中的变量。否则,将会产生错误。如果它们被用作数据库对象比如列的名字,那么可能会产生错误。

下面是神通数据库保留字列表:

abort absolute access action* add*

after* aggregate* all* alter* analyse*

analyze* and* any* archivelog* as*

asc* assertion* assignment* at* audit*

authorization* autoextend*

backward* before* begin* between* bigint*

binary* bit* block* boolean* both*

by*

cache* call* called* cascade* cascaded*

case* cast* chain* char* character*

characteristics* check* checkpoint* class* clean*

close* cluster* coalesce* collate* column*

comment* commit* committed* configuration* constraint*

constraints* controlfile* conversion* convert* copy*

create* createdb* createuser* cross* current*

currentdate* currenttime* currenttimestamp* currentuser* cursor* cycle*

database* datafile* day* dba* deallocate*

debug* dec* decimal* declare* default*

deferrable* deferred* definer* delete* delimiter*

delimiters* desc* description* distinct* do*

domain* double* drop*

each* else* encoding* encrypted* end*

escape* except* exclusive* exec* execute*

exists* explain* external* extract*

false* fetch* file* fill* float*

for* force* foreign* forward* freeze*

from* full* function*

get* global* globalname* grant* group*

handler* having* hour*

ilike* immediate* immutable* implicit* import*

in* increment* index* inherits* init*

initially* inner* inout* input * insensitive*

insert* instead* int* integer* intersect*

interval* into* invoker* is* isnull*

isolation*

join*

key* kill*

lancompiler* language* leading* left* level *

like* limit* listen* load* local *

localtime* localtimestamp* location* lock* logfile*

logging* logical*

match* maxsize* maxvalue* member* minute* minvalue* mode* month* mount* move* multiple*

names* national* natural* nchar* new*

next* no* noarchivelog* noaudit* nocreatedb* nocreateuser* nologging* nomount* none* norecompute* normal* not* nothing* notify* notnull* null* nullif* numeric*

object* of* off* offset* oids*

old* on* only* open* operator*

option* or* order* out* outer*

overlaps* overlay* owner*

parameter* paraminfo* partial* partition* password*

path* pctfree* pctused* pendant* percent*

pfile* placing* position* precision* prepare*

primary* prior* privileges* procedural* procedure*

read* real* rebuild* recheck* recovery*

references* relative* rename* repeatable* replace*

reset* resize* restrict* return* returns*

reuse* revoke* right* role* rollback*

row* rowdescription* rule*

savepoint* scan* schema* scroll* second*

security* select* sequence* serializable* session*

sessionuser* set* setof* share* show*

shutdown* similar* simple* single* size*

smallint* some* split* stable* start*

startup* statement* static* statistics* stdin*

stdout* storage* strict* substring* successful*

sysid* system*

table* tablespace* temp* template* temporary*

then* time* timestamp* tinyint* to*

toast* trail* trailing* transaction* transactional*

threat* trigger* trim* true* truncate*

trusted* tuple* type*

unencrypted* union* unique* unknown* unlimited* unlisten* unlock* until* up* update* usage* user* using*

vacuum* valid* validator* values* varbinary*

varchar* varying* verbose* version* view

volatile*

when* whenever* where* with* without*

work* write*

year*

zone

注解

有*号的为保留关键字,一般情况下用户不能使用,详细情况请参见附录B,''命名规则和保留名字空间''中关于命名规则的部分。未带*号的为非保留关键字,在任何场合都应该是可以使用的,只是使用它会造成一定的混淆,因此不推荐使用之。

下面是esql*C中使用的关键字:

allocate* append autocommit*

bool* break

call cardinality connect connection* continue count current*

data datetime_interval_code datetime_interval_precision

describe descriptor* disconnect

enum* erase export

found free*

go goto

identified indicator*

key_member

length lob long*

max

name nullable

octet_length open output*

reference* reindex release returned_length returned_octet_length

scale section short* signed* sql*

sqlerror sqlprint sqlwarning stop struct*

unsigned*

value* var

whenever

注解

有*号的为保留关键字,一般情况下用户不能使用,详细情况请参见附录B,''命名规则和保留名字空间''中关于命名规则的部分。未带*号的为非保留关键字,在任何场合都应该是可以使用的,只是使用它会造成一定的混淆,因此不推荐使用之。