Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

$

@

ALTER

BEGIN_DECLARE

CLOSE

COMMENT_ON

COMMIT

CREATE

DBKEY

DECLARE

DELETE

DESCRIBE

DROP

EDIT

END_DECLARE

EXECUTE

EXECUTE_IMMEDIATE

EXIT

EXPORT

FETCH

GRANT

HELP

IMPORT

INCLUDE

INSERT

INTEGRATE

LSE

NULL

OPEN

PREPARE

PRINT

QUIT

RELEASE

REVOKE

ROLLBACK

SELECT

SET

SET_ALL_CONSTRAINT

SET_TRANSACTION

SHOW

SQLCA

SQLDA

UPDATE

USER

WHENEVER

alias

arith expression

authorization id

col select expr

Command Recall

database handle

Data Distributor

data types

DCL invoke

default schema

Dynamic SQL

Error

Execute(@)

Functions

GRANT ANSI style

Interactive kit

Linking programs

literals

Module language

New Features

Precompiler

predicate

Release Notes

REVOKE ANSI style

Sample Databases

select expr

singleton select

Value expression

More Information

More Information

UNION

col select clause

More Information

ALL

CREATE_SCHEDULE

CREATE_TRANSFER

DROP_SCHEDULE

DROP_TRANSFER

REINITIALIZE

SHOW_TRANSFER

START_TRANSFER

Release Notes

Error msg doc

More Information

More Information

More Information

More Information

More Information

More Information

More Information

More Information

domains

Example

More Information

2DBTRISTMT

ACENOTFND

ACE_ID_OVFL

ACE_ID_UNFL

ADADISUNS

ADAVARUNS

ALTSCHATT

ALT_SCH_RDB_ERR

AMBHV_DEC

AMBTYP_DEC

AMB_KEYWORD

ANODBHAND

ARGNOTNUM

ARIEXPEXP

ASSSTRLIT

ATTMISSING

BADBLOB

BADCLUMP

BADCORATT

BADDBHAND

BADDTFMT

BADFILEVER

BADLANGUAGE

BADMAINT

BADMETNAM

BADPREPARE

BADSUPLVL

BADVERNUM

BAD_ARRAY

BAD_CDD_DEF

BAD_DB

BAD_LENGTH

BAD_LEVEL

BAD_NAME

BAD_PRECISION

BAD_SCALE

BAD_TOKEN

BAD_TXN_STATE

BAD_VERSION

BINSCAFAC

BIT_FIELD

BOGUS_CDD

BOOEXPEXP

BUGCHK

CABORT

CDDERR

CDDUNKPROT

CDDVERERR

CHECKOPTRO

CHR_TOO_SHO

CHR_TOO_SMA

CIRCTYPE

CLOSERR

CNTSPNSUB

COLEXISTS

COLNOTFUN

COLNOTNUL

COLNOTSS

COLNOTUPD

COLNOTVAL

COMTOOLON

CONALREXI

CONAMBIG

CONCHAILL

CONDICREQ

CONNOTDEF

CONNOTSUP

CONREAATT

CONSNAATT

CONTPREQ

CONTRIACT

CONVARDEF

CONVARUND

CORREFFUN

CRE_STO_ERR_SCH

CS_ERR

CURALROPE

CURNAMEXI

CURNOTOPE

CUROFNOT

CUROFSTA

CURTWOOPEN

CURUSEINV

DATCONERR

DATNOTSUP

DATTYPUNK

DBHANDUNK

DBINUSE

DBKAMBIG

DBKTOOBIG

DB_EXISTS

DB_HANDEC

DB_HANDEC2

DB_HANLON

DB_IN_TXN

DCLBEFEXE

DCLDATBEF

DDLPARAM

DECCURINTO

DEFCONMOD

DEFDBDEC

DEFVALINC

DEFVALUNS

DEGMODSPC

DELBACKUP

DIC_DB_CHG1

DIC_DB_CHG2

DIGNUMPIC

DROP_IDX

DROP_VIEW

DRO_SCH_RDB_ERR

DTFMTTOOBIG

DTONCEEACH

DUPPROCNAM

DUPREFACT

DUPVAR

DYNSIZARR

END

ENUM_VAR

ERRATTDEC

ERRATTDEF

ERRCRESCH

ERRDET

ERRINCPATH

ERRSYMDEL

ERRSYMREP

ES_ILL_RPT

EVACLAUNS

EXESELSTA

EXPNUMLIT

EXPQUEXPR

EXTRADATA

FETNOTDON

FIELD_EXISTS

FLDAMBIG

FLDNOTBCK

FLDNOTCRS

FLDNOTDEF

FLDNOTINREL

FLUINPBUF

FORPASLEN

FUN_VAR

GARBLED

GETCRESEG

GFLOAT

HEXSTREVE

HI_ORD_LOS

HVNOTDECL

HV_NOT_IN

IDMISSING

ILLBEGIN

ILLCHAR

ILLDATLEN

ILLEXEIMM

ILLFLOLEN

ILLFROM

ILLHEXNUM

ILLINTLEN

ILLPICSTR

ILLSTRCONT

IMPL_DIM

IMP_IDX_CONFLICT

IMP_IDX_TWICE

IMP_STO_CONFLICT

IMP_STO_MAP_CONFLICT

IMP_STO_MAP_TWICE

IMP_STO_TWICE

INCNOTREC

INC_DAT_TYP

INDEXTS

INDFIXINT

INDNOTDEF

INDSHOINT

IND_EXISTS

INSCOLALR

INTIGNSYS

INTNOTSYS

INTVALLOW

INTVALOVR

INVACL

INVARRSUB

INVCHAINP

INVCHANUMSTR

INVCOLLST

INVCOLSPC

INVCOMLIN

INVCONS

INVCORRSL

INVDATCON

INVDBKREF

INVDISXPR

INVESCVAL

INVFLD

INVFUNREF

INVHVDECL

INVINDEX

INVLENHV

INVNUMLIT

INVOBJFIL

INVORDNUM

INVPRIV

INVQUAL

INVREFCLA

INVRELVIEW

INVSELLIS

INVSELSTAR

INVSQLCODE

INVSSCONV

INVSSHAN

INVTRG

INVTRISTMT

INVTYPE

INVVALLIS

IOERROR

ISQLINTO

JUNONLIN

KEYTOIDENT

LANFILEXT

LANSWIVAL

LANUNSDTP

LENMISMAT

LOOK_FOR

LOOK_FOR_CON

LOOK_FOR_FIN

LOOK_FOR_STMT

LOOK_FOR_STT

LOOK_FOR_UNTERM

LOW_ORD_LOS

MAXFLDPRTSTR

MAXNESEXC

MAXRELEXC

MISREQVAL

MULDIMARR

MULSPECATR

MULTSPECATR

MULT_STRUCT

MUL_UIC

NAMCONF

NAMTOOBIG

NEG_DIM

NESFUNINV

NESINCFIL

NESQRYEXP

NOALTER

NOBATUPD

NOBCKFIL

NOBCKTRNS

NOCDD

NOCDDALT

NOCDDRES

NOCDDUPDAT

NOCMPBYRES

NOCOLALL

NOCOLNAM

NOCONNAM

NOCONRES

NOCORRCOL

NODATDIV

NODATRES

NODBKGRO

NODBNAME

NODEFDB

NOFILLIST

NOFLDRES

NOIDXRES

NOINCDIC

NOITEMDEF

NOLANGFIL

NOMAPRES

NOMATCHKEY

NOMODFIL

NONOVAL

NONSTAAMB

NONSTACAS

NONSTACOB

NONSTACOL

NONSTACON

NONSTACUC

NONSTADIS

NONSTADTP

NONSTADYN

NONSTAHV

NONSTANAM

NONSTAOKW

NONSTAPHY

NONSTAQUO

NONSTASM

NONSTASYN

NONSTATXN

NONSTAUNI

NONSTAVIA

NOOPENCUR

NOPRECOMPSEL

NOPRIMKEY

NOPROC

NORDBPRIV

NORELFOU

NORELRES

NORTPARM

NOSCHALT

NOSEGSTRAREA

NOSQLCA

NOSQLCODE

NOSTRDEF

NOSTRNAM

NOSUCHCUR

NOSUCHDATEFMT

NOSUCHLANG

NOSUCHTIMEFMT

NOTDB2

NOTFOUND

NOTGROFLD

NOTHVDECL

NOTRGRES

NOTUSEIND

NOTYPES

NOT_A_DB

NOT_CDD_DB

NOT_SAME_CONTEXT

NOT_SCH_ID

NOVIERES

NO_COMMAND

NO_DCLTXN

NO_DECIMAL

NO_DESCENDING

NO_DMLPLAN

NO_ENDCOM

NO_ENDEXEC

NO_FILFND

NO_INCFND

NO_NUMERIC

NO_PLNFND

NO_SQLDA

NO_SUCH_FIELD

NO_TXNOUT

NSEGBLR

NULLNOIND

NUMHVSNOT

NUMITESEL

NUM_TO_DATE

ONEEPERM

ONETXNMOD

ONLFIRPRE

ONLFIRVAR

ONLONEDB

ONLONETRN

ONLYONEPSECT

OPENERR

OPRSTK_OVRFLO

PARAMNOTSTR

PARAMQUAL

PARBADCLA

PARBADDAT

PARBADLEN

PARBADSCA

PARBINSCA

PARSE_STACK_OVERFLOW

PASRECUNS

PASVARUNS

PATH_NAM_REQ

PHYBACDAT

PKNOTNULL

PREFORSTR

PREMATURE_EOF

PRESTAOPE

PRIKEYEXI

PRINT_SSID

PROCNOCA

PRPSELINTO

PTR_VAR

PUTOPESEG

QUAINVVAL

QUANOVAL

RDBVMSONL

REANOWRT

REAONLATT

RECEXCMAX

REFKEYCOL

REFKEYNUM

RELAMBIG

RELNOTDEF

REL_EXISTS

REORGONLALTSM

RESABORT

RESERVED_WORD

SEGAREERR

SEGSTREXP

SELMORVAL

SEVERRDET

SHDESCEND

SHOTABMAPDR

SMA_DAT_TYP

SPACREQ

SPANOTVAL

SQLDANOT

SQLDATA

SQLTYPE

STANOTDEF

STANOTSEL

STAREQCOL

STARNOTALL

STATWOCUR

STOCOLERR

STOCOLUKN

STOTABUKN

STRARRAY

STRINXPR

STRLITEXP

STRLITMISQUO

STRMORELE

STRTOOBIG

STRTOOLON

STRXPREXP

SUBNOGB

SUBTOOVAL

SYM_EXP

SYNTAX_ERR

SYSPAGFOR

SYSPAGUNI

S_STOAREA_READONLY

S_STOAREA_READWRITE

TBLCOLAFT

TBLNOTCUR

THRIGNSYS

THRNOTSYS

TOKINSBEF

TOKTOOBIG

TOOBIGBLR

TRAACT

TRAACT_1

TRAACT_2

TRAACT_3

TRAHDLINV

TRAMODSPC

TREE_OVRFLO

TXNNOTLONG

TXN_HNDL_IGNORED

UKN_ALT_OPT

UNBDECFIL

UNBTMPFIL

UNDEFVAR

UNDPARAM

UNISELLIS

UNKTYPE

UNSDATATYPE

UNSDB2PRIV

UNSDSCCLA

UNSDTPCVT

UNSIGNED_VAR

UNSPLIATT

UNSSTRXPR

UNSSUPDAT

UNSUPOP

UNTSTR

UPDCOLPRIV

UPDREACUR

USERINVIEW

USRDEFTYP

VECNOTIND

VEWNOTDEF

WAIMODSPC

WARDET

WHYTWICE

WISH_LIST

WRICIRREF

ZABORT

Examples

More Information

More Information

WITH_GRANT_OPTION

More Information

column privs

table privs

schema privs

identifier ansi style

numeric

character string

date

More Information

Examples

More Information

Command line

More information

Qualifiers

V31

DROP_CONSTRAINT

SET_ALL_CONSTRAINTS

WITH_GRANT_OPTION

Ada Host Variables

ANSI Style Privileges

Auto Locking

Default Values

Descending Indexes

Internationalization Support

Language Sensitive Editor (LSE)

Miscellaneous

PASCAL Precompiler

PRINT Statement

Read Only System Relations

Referential Integrity

Triggers

UNION operator

Command line

More Information

Qualifiers

BETWEEN

CONTAINING

EXISTS

IN

LIKE

NULL

STARTING_WITH

UNIQUE

More Information

basic

complex

quantified

More Information

More Information

More Information

More Information

More Information

column privs ansi

table privs ansi

schema privs ansi

identifier ansi style

More Information

FROM

WHERE

GROUP_BY

HAVING

UNION

More Information

select clause

select list

More Information

More Information

Restriction

ALL

INTO

More Information

More Information

More Information

RDB/VMS SQL — VMS RDB_3.1A

Additional information available:

$@ALTERBEGIN_DECLARECLOSECOMMENT_ON
COMMITCREATEDBKEYDECLAREDELETEDESCRIBEDROP
EDITEND_DECLAREEXECUTEEXECUTE_IMMEDIATEEXIT
EXPORTFETCHGRANTHELPIMPORTINCLUDEINSERT
INTEGRATELSENULLOPENPREPAREPRINT
QUITRELEASEREVOKEROLLBACKSELECTSETSET_ALL_CONSTRAINT
SET_TRANSACTIONSHOWSQLCASQLDAUPDATEUSER
WHENEVER

aliasarith expressionauthorization idcol select expr
Command Recalldatabase handleData Distributordata types
DCL invokedefault schemaDynamic SQLErrorExecute(@)
FunctionsGRANT ANSI styleInteractive kitLinking programs
literalsModule languageNew FeaturesPrecompilerpredicateRelease Notes
REVOKE ANSI styleSample Databasesselect exprsingleton select
Value expression

alias

 A qualifier for column names.  Users can qualify a column name with
 its table or view name, or with an aribitrary alias they specify in
 the FROM clause of an SQL statement.  SQL requires aliases as
 qualifiers instead of table or view names in statements that join a
 table with itself.

arith expression

 An arithmetic expression is a value expression formed by combining
 value expressions with arithmetic operators.  When you use an
 arithmetic expression in a statement, SQL calculates the value
 associated with the expression and uses that value when executing the
 statement.  Therefore, an arithmetic expression must be reducible to
 a value.  However, SQL does not permit arithmetic operations on
 columns defined with the DATE data type.

 If either operand of an arithmetic expression is a null value, the
 resulting value is also null.

 Select More_Information to continue.

Additional information available:

More Information

More Information

 The arithmetic operators and their functions are:

 +       Add
 -       Subtract
 *       Multiply
 /       Divide

 Select More_Information to continue.

Additional information available:

More Information

More Information

 You can use parentheses to control the order in which SQL performs
 arithmetic operations.  SQL follows the normal rules of precedence.
 That is, it evaluates arithmetic expressions in the following order:

 1.  Value expressions in parentheses

 2.  Multiplication and division, from left to right

 3.  Addition and subtraction, from left to right

authorization id

 When you issue a CREATE SCHEMA or DECLARE SCHEMA statement, whether
 you specify a file specification or a data dictionary path name, you
 can specify an additional name, called an authorization identifier.
 You must specify an authorization identifier in CREATE SCHEMA but it
 is optional in DECLARE SCHEMA.

 An authorization identifier is a name for a particular attachment to
 a schema.  Explicitly specifying an authorization identifer lets your
 program or interactive SQL statements refer to more than one schema.
 Once specified, you must use the authorization identifier when
 referring to the schema in subsequent SQL statements (unless those
 statements are within a CREATE SCHEMA statement).  You must use an
 authorization identifier when you declare more than one schema.

 DIGITAL proprietary database languages (such as RDO in Rdb/VMS) use
 the term database handle instead of authorization identifier.  The
 two terms mean the same thing.  The keywords AUTHORIZATION ID in SQL
 and DB_HANDLE in RDO are also synonymous.

col select expr

 col-select expr =

 ───┬─┬─> col-select-clause  ───┬───>
    │ └─> ( col-select-expr ) ──┤
    │ ┌────────────<────────────┘
    │ └─> 
U

N

I

O

N
───┬───────┬────┐ │ └─>
A

L

L
─┘ │ └──────────<────────────────┘

Additional information available:

UNION

col select clauseMore Information

col select clause

 col-select-clause =

 SELECT ─┬──────>──────┬─┬─> typebox (*) ────────────────────┬─┐
         ├─> 
A

L

L
──────┤ ├─> table-name ──┬─> .typebox (*) ──┤ │ └─> 
D

I

S

T

I

N

C

T
─┘ ├─> view-name ───┤ │ │ ├─> alias ───────┘ │ │ └─> value-expr ───────────┘ │ ┌────────────────────────────────<────────────────┘ └ 
F

R

O

M
─┬┬─> table-name ─┬─┬─────>────┬─┬─┬─────────>──────────┬─┐ │└─> view-name ──┘ └─> alias ─┘ │ └─> 
W

H

E

R

E
predicate ─┘ │ └────────── , <─────────────────┘ │ ┌──────────────────────────────<─────────────────────────────────┘ └┬─────────────>──────────────────┬─┬──────────>──────────┬──> └─> 
G

R

O

U

P

B

Y
─┬─> column-name ─┬─┘ └─> 
H

A

V

I

N

G
predicate ─┘ └─────── , <─────┘

UNION

 The union operator merges the results of a select expression or
 select clause with another select expression or select clause into
 one result table by appending the values of columns in one table with
 the values of columns in other tables.

Additional information available:

ALL

ALL

 The ALL qualifier specifies that duplicate rows should not be
 eliminated from the result table.

More Information

 A column select expression is a select expression that specifies a
 one-column result table.  Column select expressions cannot specify a
 list of select items.

 SQL accepts a column select expression as a type of value expression.
 However, since a value expression must correspond to a single value,
 a column select expression used as a value expression should not
 return more than one value.  If it does, SQL generates an error.  A
 column select expression used as a value expression cannot include
 GROUP BY or HAVING clauses.

                                 NOTE

         IN predicates allow column select expressions used as
         value expressions to return more than one value.


 Column select expressions are also called subqueries.

Command Recall

 Interactive SQL users can recall the 20 most recent command lines
 using the up and down arrow keys or the CTRL/B key sequence:

  o  The up arrow key recalls lines in sequence from most recent to
     least recent.

  o  The CTRL/B key sequence also recalls lines in sequence from most
     recent to least recent.

  o  After you have recalled prior lines, the down arrow key allows
     you to recall more recently entered lines.

database handle

 DIGITAL proprietary database languages (such as RDO in Rdb/VMS) use
 the term database handle instead of authorization identifier.  The
 two terms mean the same thing.  The keywords AUTHORIZATION ID in SQL
 and DB_HANDLE in RDO are also synonymous.  For more information see
 the Help topic on authorization_id.

Data Distributor

 VAX Data Distributor is a software product that lets you distribute
 whole databases, or parts of them, to target directories on the same
 or different nodes in the network.  Data Distributor allows two types
 of distribution, or 'transfers':

 Extraction databases once created are independent of the source
 databases.  Updates to the source database are not reflected in the
 extraction database.  Users can update the extraction database.

 Replication databases remain dependent on the source databases after
 creation.  Subsequent transfers supply updates from the source
 database to the replication database.  Users cannot update the
 replication database.

 You can issue Data Distributor statements, options, and qualifiers
 from SQL when VAX Data Distributor is installed on your system.  See
 the VAX Data Distributor Handbook and the SQL Reference Manual for
 details of the Data Distributor statements.

Additional information available:

CREATE_SCHEDULECREATE_TRANSFERDROP_SCHEDULEDROP_TRANSFER
REINITIALIZESHOW_TRANSFERSTART_TRANSFER

Release NotesError msg doc

Release Notes

 To see the current Release Notes for VAX Data Distributor, type or
 print the following file:

     SYS$HELP:DDALvvu.RELEASE_NOTES

         where    vv = version
                  u  = update

 For example:

     SYS$HELP:DDAL020.RELEASE_NOTES

Error msg doc

 Errors returned by Data Distributor are documented online in the file
 SYS$HELP:DDAL$MSG.DOC, which you can PRINT, TYPE, or SEARCH at DCL
 level.

CREATE_SCHEDULE

 CREATE SCHEDULE FOR ────> transfer-name ────────┐
 ┌───────────────────────────────────────────────┘
 └─┬──>────────────────────────────────────┬─────┐
   └──> 
S

T

A

R

T
─────> start-date-time ──────┘ │ ┌───────────────────────────────────────────────┘ └─┬──>────────────────────────────────────────┬─┐ └──> 
E

V

E

R

Y
──┬──> every-delta-time ───────┬─┘ │ └──> every-absolute-time ────┘ │ ┌───────────────────────────────────────────────┘ └─┬──────────────────────────────────────────────────────────────┬──> typebox (;) └──> 
R

E

T

R

Y
─> count ─> 
T

I

M

E

S
─┬──────────────────────────────┬─┘ └─> 
R

E

T

R

Y

E

V

E

R

Y
─> delta-time ─┘

Additional information available:

More Information

More Information

 Creates a schedule definition and stores it in the transfer database.
 The schedule definition specifies when and how often a transfer
 should execute.  A transfer can have only one schedule definition
 associated with it.  Data Distributor returns an error if you attempt
 to create a schedule for a transfer that already has one.

CREATE_TRANSFER

 CREATE TRANSFER ───> transfer-name ───> 
T

Y

P

E
typebox (I)typebox (S) ─────────────────┐ ┌────────────────────────────────────────────────────────────────┘ └─┬──> 
R

E

P

L

I

C

A

T

I

O

N
───> replication-extr-move-clause ─────────┬──┐ ├──> 
E

X

T

R

A

C

T

I

O

N
───> replication-extr-move-clause ──────────┤ │ └──> 
E

X

T

R

A

C

T

I

O

N

R

O

L

L

U

P
───> rollup-move-clause ─────────────┘ │ ┌────────────────────────────────────────────────────────────────┘ └─> 
T

O
───> target-file-spec ──┬───────────────────────────────┬─┐ └─┬─> target-db-param-clause ──┬┘ │ └─────────────<──────────────┘ │ ┌────────────────────────────────────────────────────────────────┘ └┬─────────────────────────────────────┬─┬───────────────────┬─> typebox (;) └─┬─> transfer-file-options-clause ─┬─┘ └─> comment-clause ─┘ └──────────────────<──────────────┘

Additional information available:

More Information

More Information

 Creates a transfer definition and stores it in the transfer database.
 A transfer definition contains all of the information necessary to
 select a set of records from the source database and to define a
 target database.  A transfer definition also can contain the views to
 be defined on the target database and the command procedures to be
 executed before and after the execution of the transfer.

DROP_SCHEDULE

 DROP SCHEDULE FOR ───> transfer-name ────> typebox (;)

Additional information available:

More Information

More Information

 Deletes the schedule definition associated with a transfer
 definition.  You can delete a schedule definition only when the
 associated transfer is in the suspended state.  (Refer to the STOP
 TRANSFER statement for information about how to suspend a transfer.)
 If you issue a START TRANSFER statement after deleting the schedule,
 the transfer will be placed in the unscheduled state.

DROP_TRANSFER

 DROP TRANSFER ───> transfer-name ────> typebox (;)

Additional information available:

More Information

More Information

 Deletes a transfer definition.  If a transfer has a schedule
 definition, DROP TRANSFER also deletes the corresponding schedule
 definition.

REINITIALIZE

 REINITIALIZE TRANSFER ─────> transfer-name ─────> typebox (;)

Additional information available:

More Information

More Information

 Reinitializes a replication transfer to make the source and
 replication databases consistent with each other.  You must
 reinitialize a transfer when someone restores a previous version of
 the source database.

SHOW_TRANSFER

 SHOW TRANSFER ┬───────────────────────────────────────────────┬─> typebox (;)
               └┬───────────────────────┬┬──> typebox (*) ──────────────┬┘
                └─> transfer-attribute ─┘└┬─> transfer-name ─┬┘
                                          └─────── , <───────┘

 transfer-attribute =

 ────> ( ─┬─┬──> 
D

E

F

I

N

I

T

I

O

N
───┬─┬─ ) ──> │ ├──> 
S

C

H

E

D

U

L

E
─────┤ │ │ └──> 
S

T

A

T

U

S
───────┘ │ └───────── , <─────────┘

Additional information available:

More Information

More Information

 Displays information about the transfer definition, schedule
 definition, the transfer status, or all of these transfer attributes.

START_TRANSFER

 START TRANSFER ────> transfer-name ───┬──────────────────────────┬───> typebox (;)
                                       └──> 
N

O

W
──┬─>───────────┬─┘ ├─> 
W

A

I

T
─────┤ └─> 
N

O

W

A

I

T
──┘

Additional information available:

More Information

More Information

 Executes a transfer on demand, or changes the state of a transfer
 from suspended to scheduled, unscheduled, or active.

data types

 data-type =

 ──┬─> 
C

H

A

R
─┬────────┬───────────────────────────┬──> │ └─> (n) ─┘ │ ├─> 
V

A

R

C

H

A

R
(n) ───────────────────────────────┤ ├─> 
L

O

N

G

V

A

R

C

H

A

R
──────────────────────────────┤ ├─> 
S

M

A

L

L

I

N

T
──┬─┬────────┬────────────────────┤ ├─> 
I

N

T

E

G

E

R
───┤ └─> (n) ─┘ │ ├─> 
Q

U

A

D

W

O

R

D
──┘ │ ├─> 
D

E

C

I

M

A

L
─┬─┬─────────────────────────────┬─┤ ├─> 
N

U

M

E

R

I

C
─┘ └─> ( ──> n ─┬────────┬─> ) ──┘ │ │ └─> , n ─┘ │ ├─> 
F

L

O

A

T
─┬────────┬──────────────────────────┤ │ └─> (n) ─┘ │ ├─> 
R

E

A

L
──────────────────────────────────────┤ ├─> 
D

O

U

B

L

E

P

R

E

C

I

S

I

O

N
──────────────────────────┤ └─> 
D

A

T

E
──────────────────────────────────────┘

Additional information available:

More Informationdomains

More Information

 Data types control how SQL interprets and stores values in columns.
 Literals, arithmetic expressions, parameters, and SQL functions are
 examples of expressions other than column names that supply values
 and also have associated data types.

domains

 A domain is the set of values that a column in a table can have.  The
 CREATE DOMAIN statement specifies the set of values by associating a
 data type with a domain name.

 You can refer to a domain instead of an SQL data type in the CREATE
 and ALTER TABLE statements, and in formal parameter declarations in
 SQL module procedures.  You can specify the same domain in many table
 definitions.  If the domain has to change, you need only change that
 one domain definition to change all the tables and SQL modules that
 refer to it.  This ability makes it easier to keep applications
 consistent

DCL invoke

 Gives access to DCL from inside interactive SQL.

 The dollar sign ($) instructs interactive SQL to spawn a subprocess
 and pass the rest of the command line to DCL for processing.  You
 must follow the dollar sign with a DCL command.  After DCL processes
 the command, it logs out of the subprocess and returns control to
 interactive SQL.  For example:

 SQL> $ MAIL

 MAIL>

Additional information available:

Example

Example

 Seeing your current default VMS directory:

 SQL> $ DIRECTORY

 Directory DISK2:[DEPT3.ACCT]

 DEFPRO.SQL;6    NOTEQUAL.SQL;1   QUERY.SQL;1    REFEXAM.SQL;12
 STORE.SQL;1     UPDATE.SQL;2

 Total of 6 files.

 SQL>

default schema

 SQL allows you to specify an authorization identifier that declares
 the schema as the default schema.  Specifying a default schema means
 that subsequent statements during the database attachment that refer
 to the default schema need not use an authorization identifier.

 In the SQL module language, the authorization identifier specified in
 the module header is the one that designates the default schema.  In
 precompiled SQL programs and in interactive SQL, the special
 authorization identifier RDB$DBHANDLE designates the default schema.
 In all environments, omitting an explicit authorization identifier is
 the same as specifying the authorization identifier that designates
 the default schema.

 Select More_Information to continue.

Additional information available:

More Information

More Information

 If you do not declare any schema, SQL declares the schema specified
 in the logical name SQL$DATABASE as the default schema, using the FOR
 FILENAME clause.

 If you declare a schema specifying an authorization identifier other
 than the one that declares the default schema, you must use that
 authorization identifier to qualify names of any schema entities to
 which you refer in SQL statements.  If you omit the authorization
 identifier, SQL assumes the table or view must be part of the default
 schema.  If there is no default schema and you omit the authorization
 identifier, SQL generates an error.

Dynamic SQL

 Dynamic SQL lets programs accept or generate SQL statements at run
 time, in contrast to SQL statements that are part of the source code
 for precompiled programs or SQL module language procedures.  Unlike
 precompiled SQL or SQL module language statements, such dynamically
 executed SQL statements are not necessarily part of a program's
 source code, but can be created while the program is running.
 Dynamic SQL is useful when you cannot predict the type of SQL
 statement your program will need to process.

 You cannot use dynamic SQL statements in interactive SQL, but
 interactive help includes quick reference information on these
 dynamic SQL statements:

 DESCRIBE
 EXECUTE
 EXECUTE IMMEDIATE
 INCLUDE
 PREPARE

Error

 The following topics document messages returned with the SQL facility
 code.  The online file SYS$HELP:SQL$MSG.DOC contains the same text.
 Print that file if you need hardcopy SQL message documentation.

 The Appendix on error messages in the VAX SQL Reference Manual
 describes how to use this file and files documenting related error
 messages with other facility codes.

Additional information available:

2DBTRISTMTACENOTFNDACE_ID_OVFLACE_ID_UNFL
ADADISUNSADAVARUNSALTSCHATTALT_SCH_RDB_ERR
AMBHV_DECAMBTYP_DECAMB_KEYWORDANODBHAND
ARGNOTNUMARIEXPEXPASSSTRLITATTMISSING
BADBLOBBADCLUMPBADCORATTBADDBHANDBADDTFMT
BADFILEVERBADLANGUAGEBADMAINTBADMETNAM
BADPREPAREBADSUPLVLBADVERNUMBAD_ARRAY
BAD_CDD_DEFBAD_DBBAD_LENGTHBAD_LEVEL
BAD_NAMEBAD_PRECISIONBAD_SCALEBAD_TOKEN
BAD_TXN_STATEBAD_VERSIONBINSCAFACBIT_FIELDBOGUS_CDD
BOOEXPEXPBUGCHKCABORTCDDERRCDDUNKPROT
CDDVERERRCHECKOPTROCHR_TOO_SHOCHR_TOO_SMA
CIRCTYPECLOSERRCNTSPNSUBCOLEXISTSCOLNOTFUN
COLNOTNULCOLNOTSSCOLNOTUPDCOLNOTVAL
COMTOOLONCONALREXICONAMBIGCONCHAILL
CONDICREQCONNOTDEFCONNOTSUPCONREAATT
CONSNAATTCONTPREQCONTRIACTCONVARDEF
CONVARUNDCORREFFUNCRE_STO_ERR_SCHCS_ERR
CURALROPECURNAMEXICURNOTOPECUROFNOT
CUROFSTACURTWOOPENCURUSEINVDATCONERR
DATNOTSUPDATTYPUNKDBHANDUNKDBINUSE
DBKAMBIGDBKTOOBIGDB_EXISTSDB_HANDECDB_HANDEC2
DB_HANLONDB_IN_TXNDCLBEFEXEDCLDATBEF
DDLPARAMDECCURINTODEFCONMODDEFDBDECDEFVALINC
DEFVALUNSDEGMODSPCDELBACKUPDIC_DB_CHG1
DIC_DB_CHG2DIGNUMPICDROP_IDXDROP_VIEW
DRO_SCH_RDB_ERRDTFMTTOOBIGDTONCEEACHDUPPROCNAM
DUPREFACTDUPVARDYNSIZARRENDENUM_VAR
ERRATTDECERRATTDEFERRCRESCHERRDET
ERRINCPATHERRSYMDELERRSYMREPES_ILL_RPT
EVACLAUNSEXESELSTAEXPNUMLITEXPQUEXPR
EXTRADATAFETNOTDONFIELD_EXISTSFLDAMBIG
FLDNOTBCKFLDNOTCRSFLDNOTDEFFLDNOTINREL
FLUINPBUFFORPASLENFUN_VARGARBLEDGETCRESEG
GFLOATHEXSTREVEHI_ORD_LOSHVNOTDECL
HV_NOT_INIDMISSINGILLBEGINILLCHARILLDATLENILLEXEIMM
ILLFLOLENILLFROMILLHEXNUMILLINTLENILLPICSTRILLSTRCONT
IMPL_DIMIMP_IDX_CONFLICTIMP_IDX_TWICEIMP_STO_CONFLICT
IMP_STO_MAP_CONFLICTIMP_STO_MAP_TWICEIMP_STO_TWICE
INCNOTRECINC_DAT_TYPINDEXTSINDFIXINTINDNOTDEF
INDSHOINTIND_EXISTSINSCOLALRINTIGNSYSINTNOTSYSINTVALLOW
INTVALOVRINVACLINVARRSUBINVCHAINPINVCHANUMSTR
INVCOLLSTINVCOLSPCINVCOMLININVCONSINVCORRSL
INVDATCONINVDBKREFINVDISXPRINVESCVALINVFLD
INVFUNREFINVHVDECLINVINDEXINVLENHVINVNUMLIT
INVOBJFILINVORDNUMINVPRIVINVQUALINVREFCLA
INVRELVIEWINVSELLISINVSELSTARINVSQLCODE
INVSSCONVINVSSHANINVTRGINVTRISTMTINVTYPE
INVVALLISIOERRORISQLINTOJUNONLINKEYTOIDENTLANFILEXT
LANSWIVALLANUNSDTPLENMISMATLOOK_FOR
LOOK_FOR_CONLOOK_FOR_FINLOOK_FOR_STMTLOOK_FOR_STT
LOOK_FOR_UNTERMLOW_ORD_LOSMAXFLDPRTSTRMAXNESEXC
MAXRELEXCMISREQVALMULDIMARRMULSPECATR
MULTSPECATRMULT_STRUCTMUL_UICNAMCONFNAMTOOBIG
NEG_DIMNESFUNINVNESINCFILNESQRYEXPNOALTER
NOBATUPDNOBCKFILNOBCKTRNSNOCDDNOCDDALTNOCDDRES
NOCDDUPDATNOCMPBYRESNOCOLALLNOCOLNAM
NOCONNAMNOCONRESNOCORRCOLNODATDIVNODATRES
NODBKGRONODBNAMENODEFDBNOFILLISTNOFLDRES
NOIDXRESNOINCDICNOITEMDEFNOLANGFILNOMAPRES
NOMATCHKEYNOMODFILNONOVALNONSTAAMBNONSTACAS
NONSTACOBNONSTACOLNONSTACONNONSTACUC
NONSTADISNONSTADTPNONSTADYNNONSTAHVNONSTANAM
NONSTAOKWNONSTAPHYNONSTAQUONONSTASM
NONSTASYNNONSTATXNNONSTAUNINONSTAVIA
NOOPENCURNOPRECOMPSELNOPRIMKEYNOPROC
NORDBPRIVNORELFOUNORELRESNORTPARMNOSCHALTNOSEGSTRAREA
NOSQLCANOSQLCODENOSTRDEFNOSTRNAMNOSUCHCUR
NOSUCHDATEFMTNOSUCHLANGNOSUCHTIMEFMTNOTDB2
NOTFOUNDNOTGROFLDNOTHVDECLNOTRGRESNOTUSEIND
NOTYPESNOT_A_DBNOT_CDD_DBNOT_SAME_CONTEXT
NOT_SCH_IDNOVIERESNO_COMMANDNO_DCLTXN
NO_DECIMALNO_DESCENDINGNO_DMLPLANNO_ENDCOM
NO_ENDEXECNO_FILFNDNO_INCFNDNO_NUMERIC
NO_PLNFNDNO_SQLDANO_SUCH_FIELDNO_TXNOUT
NSEGBLRNULLNOINDNUMHVSNOTNUMITESEL
NUM_TO_DATEONEEPERMONETXNMODONLFIRPRE
ONLFIRVARONLONEDBONLONETRNONLYONEPSECTOPENERR
OPRSTK_OVRFLOPARAMNOTSTRPARAMQUALPARBADCLA
PARBADDATPARBADLENPARBADSCAPARBINSCA
PARSE_STACK_OVERFLOWPASRECUNSPASVARUNS
PATH_NAM_REQPHYBACDATPKNOTNULLPREFORSTR
PREMATURE_EOFPRESTAOPEPRIKEYEXIPRINT_SSID
PROCNOCAPRPSELINTOPTR_VARPUTOPESEGQUAINVVAL
QUANOVALRDBVMSONLREANOWRTREAONLATT
RECEXCMAXREFKEYCOLREFKEYNUMRELAMBIG
RELNOTDEFREL_EXISTSREORGONLALTSMRESABORT
RESERVED_WORDSEGAREERRSEGSTREXPSELMORVAL
SEVERRDETSHDESCENDSHOTABMAPDRSMA_DAT_TYP
SPACREQSPANOTVALSQLDANOTSQLDATASQLTYPESTANOTDEF
STANOTSELSTAREQCOLSTARNOTALLSTATWOCUR
STOCOLERRSTOCOLUKNSTOTABUKNSTRARRAY
STRINXPRSTRLITEXPSTRLITMISQUOSTRMORELESTRTOOBIG
STRTOOLONSTRXPREXPSUBNOGBSUBTOOVAL
SYM_EXPSYNTAX_ERRSYSPAGFORSYSPAGUNIS_STOAREA_READONLY
S_STOAREA_READWRITETBLCOLAFTTBLNOTCUR
THRIGNSYSTHRNOTSYSTOKINSBEFTOKTOOBIG
TOOBIGBLRTRAACTTRAACT_1TRAACT_2TRAACT_3TRAHDLINV
TRAMODSPCTREE_OVRFLOTXNNOTLONGTXN_HNDL_IGNORED
UKN_ALT_OPTUNBDECFILUNBTMPFILUNDEFVAR
UNDPARAMUNISELLISUNKTYPEUNSDATATYPEUNSDB2PRIV
UNSDSCCLAUNSDTPCVTUNSIGNED_VARUNSPLIATT
UNSSTRXPRUNSSUPDATUNSUPOPUNTSTRUPDCOLPRIV
UPDREACURUSERINVIEWUSRDEFTYPVECNOTIND
VEWNOTDEFWAIMODSPCWARDETWHYTWICE
WISH_LISTWRICIRREFZABORT

2DBTRISTMT

 Triggered statement is not in the same schema as the trigger

 Explanation:  You specified a triggered statement which uses a
 different      schema than the schema the trigger is a part of.
 This is not

 User Action:  Specify only triggered actions which execute in
 the schema in  which the trigger is defined.

ACENOTFND

 No matching access control entry found

 Explanation:  In a protection command that refers to an existing
 access control entry, you specified identifiers that did not
 match any existing entry.

 User Action:  Use SHOW PROTECTION to see what the access control
 list currently looks like, and correct your command.

ACE_ID_OVFL

 ACE identifier stack overflow during ACE parsing

 Explanation:  You included too many identifiers in an
 expression.  The identifier stack for the access control entry
 (ACE) overflowed during parsing.

 User Action:  Simplify the access control entry that caused the
 error.

ACE_ID_UNFL

 ACE identifier stack underflow during ACE parsing

 Explanation:  The access control entry (ACE) identifier stack
 underflowed during ACE parsing.  This happens when identifiers
 are not stored in the stack appropriately.

 User Action:  Submit a software performance report (SPR) with
 the Rdb/VMS interchange file (.RBR).

ADADISUNS

 Host variable <text> is based on a type that uses discriminamts

 Explanation:  The host variable you referred to is based on a
 type which uses Ada discriminants.  VAX SQL does not support
 types which include discriminants

 User Action:  Use a different type defintion.

ADAVARUNS

 Host variable <text> is based on a record type that uses
 variants

 Explanation:  The host variable you referred to is based on a
 record type which uses Ada variants.  VAX SQL does not support
 types which include variants.

 User Action:  Use a different type defintion.

ALTSCHATT

 The ALTER SCHEMA statment cannot be used on a declared schema

 Explanation:  There was an attempt to alter a schema that was
 already        declared.

 User Action:  Either remove the ALTER SCHEMA statment or make
 sure that the  schema to be altered has not been declared.

ALT_SCH_RDB_ERR

 ALTER SCHEMA is only supported with Rdb/VMS Version 3.0 or later

 Explanation:  The ALTER SCHEMA requires Rdb/VMS V3.0.  VAX SQL
 will not alter schemas without Rdb/VMS Version 3.0 or later
 installed on the system.

 User Action:  Install the Rdb/VMS Version 3.0 or later.

AMBHV_DEC

 Host variable <text> was ambiguously defined

 Explanation:  You declared a host variable ambiguously by using
 the same name in two host variable declarations.

 User Action:  Change the name or level of one of the
 definitions.

AMBTYP_DEC

 Host variable <text> was based on an ambiguously defined type

 Explanation:  You declared a host variable which was based on a
 type.  The type is ambiguous because two or more type
 declarations use the same name.

 User Action:  Change the name or scope of one of the
 definitions.

AMB_KEYWORD

 Ambiguous keyword abbreviation

 Explanation:  You used an ambiguous abbreviation.

 User Action:  Specify the entire keyword.

ANODBHAND

 Another schema already declared with authorization identifier
 <text>

 Explanation:  You specified in the DECLARE SCHEMA statement the
 same authorization identifier as in a previous DECLARE SCHEMA
 statement.

 User Action:  Either issue a FINISH statement and try the same
 DECLARE SCHEMA statement, or enter the DECLARE SCHEMA statement
 again with a different authorization identifier.

ARGNOTNUM

 Argument must be numeric

 Explanation:  The expression for an AVG or SUM function must be
 numeric.

 User Action:  Change the value expression to contain only
 numeric fields, or remove the function.

ARIEXPEXP

 Expected arithmetic value expression

 Explanation:  You supplied a predicate where SQL expected to
 find an arithmetic value expression.

 User Action:  You must use an arithmetic value expression in
 this context.

ASSSTRLIT

 Numeric literal is assumed to be text

 Explanation:  You tried to store a numeric literal into a text
 column or compare a numeric literal to a text column.  SQL
 assumes the string is a text literal and converts it for the
 storage or comparison.  Note that each digit in the numeric
 literal, including leading zeroes, is converted to text.  For
 instance, 001 and 1 represent the same number, but are converted
 to different literals ("001" and "1").

 User Action:  None.  However, it is good programming practice to
 convert the numeric literal to a string literal by enclosing it
 in quotes.

ATTMISSING

 invalid or missing attributes

 Explanation:  Internal error -- a required attribute (such as
 the data type in a GLOBAL FIELD clump) is missing.

 User Action:  Submit an SPR with a copy of the Rdb/VMS
 interchange file (.RBR) that caused the error.

BADBLOB

 unable to import a segmented string

 Explanation:  Error from Rdb$CREATE_SEGMENTED_STRING.  See the
 following message for more information.

 User Action:  If the nature of the problem is not obvious,
 submit an SPR with a copy of the Rdb/VMS interchange file (.RBR)
 that caused the error.

BADCLUMP

 invalid clump type encountered

 Explanation:  Internal error - bad data in the Rdb/VMS
 interchange file (.RBR).

 User Action:  Submit an SPR with a copy of the Rdb/VMS
 interchange file (.RBR) that caused the error.

BADCORATT

 invalid core attribute <hex-value>, <hex-value> in .RBR file

 Explanation:  Internal error - bad data in the Rdb/VMS
 interchange file (.RBR).

 User Action:  Submit an SPR with a copy of the Rdb/VMS
 interchange file (.RBR) that caused the error.

BADDBHAND

 Authorization identifier <text> not used by this query

 Explanation:  You used an authorization identifier to qualify a
 reference to a column and that authorization identifier was not
 specified in the FROM clause of the query.

 User Action:  Either remove the authorization identifier that
 qualifies the select-list item or specify the same authorization
 identifier as specified in the FROM clause of the query.

BADDTFMT

 Date or time format is not set up properly.

 Explanation:  User entered SHOW DATE FORMAT statement, but the
 definition of LIB$DT_FORMAT turned up a bogus logical.

 User Action:  Check the definition of LIB$DT_FORMAT.  If it is a
 process logical, it should be changed.  If it is a group
       or system logical, contact the system manager to change
 it.

BADFILEVER

 incompatible .RBR file type

 Explanation:  This version of SQL cannot import a database from
 this Rdb/VMS interchange file (.RBR).

 User Action:  Use a version of RDO that corresponds to the
 version of RDO that created this file.

BADLANGUAGE

 Language <text> not set up properly.

 Explanation:  Attempting to retrieve month or weekdays from the
 logical name table LNM$LANGUAGE_xxx for language xxx, a
        value could not be retrieved.

 User Action:  Contact the sytem manager to make sure everything
 has been properly set up.

BADMAINT

 Database is an unsupported maintenance release for the current
 version

 Explanation:  The maintainance release number and the version
 number of the database that you just attached to forms an
 unknown combination.

 User Action:  Check to make sure that you are running with the
 correct versions of Digital-supported database products for VAX
 SQL.  Correct versions are listed in the VAX SQL Installation
 Guide.

BADMETNAM

 Metadata names must end in A - Z or 0 - 9

 Explanation:  The name given in a data manipulation or
 definition statement ended with a dollar sign ($) or underscore
 (_).  These symbols are not allowed.

 User Action:  Specify a valid name.

BADPREPARE

 Cannot use DESCRIBE or EXECUTE on a statement that is not
 prepared

 Explanation:  You attempted to use a DESCRIBE or EXECUTE
 statement that named a statement which was not successfully
 prepared.

 User Action:  Prepare the statement before calling DESCRIBE or
 EXECUTE.

BADSUPLVL

 Attached database has unknown support level.

 Explanation:  The database you just attached to has an unknown
 support level.

 User Action:  Check to make sure that you are using
 Digital-supported database products for VAX SQL.

BADVERNUM

 Attached database has unsupported version number.

 Explanation:  The database you just attached to has a version
 number that is not supported by this version of VAX SQL.

 User Action:  Check to make sure that you are running with the
 correct versions of Digital-supported database products for VAX
 SQL.  Correct versions are listed in the VAX SQL Installation
 Guide.

BAD_ARRAY

 Host variable <text> contains an array syntax error in its
 declaration.

 Explanation:  The named variable is defined as a C array, but is
 either missing the closing "]" or contains a non-numeric
 dimension.

 User Action:  Correct the syntax of the declaration and
 recompile the program.

BAD_CDD_DEF

 CDD$DEFAULT is not valid, data dictionary default is now
 CDD$TOP.

 Explanation:  Your logical name CDD$DEFAULT is not acceptable to
 the data dictionary.  The data dictionary will be used, but your
 default is set to CDD$TOP.

 User Action:  Define a valid CDD$DEFAULT.

BAD_DB

 Data dictionary description of current schema is corrupt

 Explanation:  The data dictionary description of the schema is
 missing the RDB$INSTANCE node.

 User Action:  Verify that the schema itself has not been
 corrupted.  If it has, recreate the schema.

BAD_LENGTH

 Negative length specified for column <text>

 Explanation:  You specified a length for a character or varchar
 column that was less than zero.

 User Action:  Change the length to a positive number.

BAD_LEVEL

 CONSISTENCY LEVEL <value> is illegal

 Explanation:  Only values 2 and 3 are allowed for consistency
 level.

 User Action:  Enter 2 for concurrency; enter 3 for consistency

BAD_NAME

 Identifiers and names may not exceed 31 characters in length

 Explanation:  The name given in a data manipulation or data
 definition statement was longer than the permitted limit.

 User Action:  For data definition statements, specify a shorter
 name.  For data manipulation statements, consult your database
 design specifications to find the correct name.

BAD_PRECISION

 Invalid precision specified for column <text>

 Explanation:  The precision specified for a DECIMAL or NUMERIC
 column is less than or equal to zero.  Or, the precision
 specified for a FLOAT column was less than zero or greater than
 15.

 User Action:  Change the precision to a valid value.

BAD_SCALE

 Negative scale specified for column <text>

 Explanation:  The scale specified for a column is less than
 zero.

 User Action:  Change the scale to a positive number.

BAD_TOKEN

 <text> is not a valid SQL language element

 Explanation:  The indicator string is neither a predefined
 language element (i.e.  a keyword, delimiter or operator) not a
 valid SQL name.

 User Action:  Use a valid SQL language element.

BAD_TXN_STATE

 Invalid transaction state.  Transaction already started.

 Explanation:  A SET TRANSACTION statement was executed, but it
 was not the first statement executed in the transaction.

 User Action:  Make the SET TRANSACTION statement the first
 statement to be executed.

BAD_VERSION

 This database system does not support this statement

 Explanation:  This statement uses a DSRI feature which is not
 supported by   all versions of all DSRI database systems.  You
 tried to       execute this statement  using a version of a
 database system        which does not support this feature.

 User Action:  Use a simpler statement, or a different base
 system version.

BINSCAFAC

 Host variable <text> has a binary scale factor

 Explanation:  The host variable is a PL/I fixed binary data type
 with a nonzero binary scale factor.  SQL supports only decimal
 scale factors.

 User Action:  Either change the scale factor to zero, or change
 the data type to fixed decimal.

BIT_FIELD

 Host variable <text> is a bit field which is illegal in SQL
 statements.

 Explanation:  The named variable is defined as a C bit field.
 Such fields are not legal in SQL statements.

 User Action:  Use a different variable.

BOGUS_CDD

 Installed version of data dictionary does not support this SQL
 version.

 Explanation:  The version of the data dictionary on your system
 does not contain the necessary SQL support.

 User Action:  Upgrade the version of data dictionary on your
 system.  Alternatively, do not access the data dictionary with
 this version of SQL.

BOOEXPEXP

 Expected a predicate

 Explanation:  Either a numeric or string value expression was
 found where SQL expected a predicate.

 User Action:  You must use a predicate in this context.

BUGCHK

 There has been a fatal error.  Please submit an SPR.  No dump
 was produced

 Explanation:  A fatal error has occurred.

 User Action:  Submit an SPR with information about the
 circumstances under which the bug occurred.  Note that
 SQL$_BUGCHECKs do not produce dumps as RDB$_BUGCHECKs do.

CABORT

 User entered Control-C to abort statement

 Explanation:  You typed a Control-C to abort the current
 statement.

 User Action:  None.

CDDERR

 Error occurred during attempt to use data dictionary.  Data
 dictionary will not be used

 Explanation:  An error occurred when SQL attempted to access the
 data dictionary.

 User Action:  Refer to following data dictionary messages for
 more information.

CDDUNKPROT

 Unknown data dictionary protocol <text>

 Explanation:  The protocol in the data dictionary was not
 correct.

 User Action:  Try to recreate the data dictionary.  If the data
 dictionary is still corrupt, submit an SPR.  Try invoking it
 with the file name.

CDDVERERR

 Found data dictionary core_level <value> was expecting <value>

 Explanation:  The core_level in the data dictionary was not
 correct.

 User Action:  Try to recreate the data dictionary.  If the data
 dictionary is still corrupt, submit an SPR.  Try invoking it
 with the file name.

CHECKOPTRO

 You specified WITH CHECK OPTION for read only view <text>

 Explanation:  You specified the WITH CHECK OPTION for a view
 which is based         on a read only select expression.  WITH
 CHECK OPTION only      makes sense for a read write view.

 User Action:  Remove the WITH CHECK OPTION clause from this view
 definition,    or make the select expression specify an
 updatable select       expression.

CHR_TOO_SHO

 Character length of column <text> is too short

 Explanation:  The character string length is too short to
 contain all possible   converted data already stored in the
 column.

 User Action:  None.  This is a warning message only.

CHR_TOO_SMA

 The string length of column <text> is too small

 Explanation:  The length of the character string is too small to
 handle         all possible numeric data that might already be
 stored in      the table.

 User Action:  None.  This is a warning message only.

CIRCTYPE

 Host variable <text> is based on a type which was used in its
 own definition

 Explanation:  You referred to a host variable which is based on
 a type.  The type was not validly defined because it was based
 on itself.

 User Action:  Fix the type definition.

CLOSERR

 error detected when closing .RBR file

 Explanation:  See the message that follows for details.

 User Action:  In the absence of other error messages, the
 database has probably been imported successfully.

CNTSPNSUB

 Cannot spawn subprocess

 Explanation:  The preprocessor was unable to spawn a subprocess
 to compile the program.

 User Action:  Read the next message and determine what to do.

COLEXISTS

 Column <text> is named more than once in table <text>

 Explanation:  You attempted to create a table or view with using
 a column name more than once.

 User Action:  Choose a different name for each column.

COLNOTFUN

 Column <text> named outside a function in a SELECT with HAVING
 but no GROUP BY

 Explanation:  In select expressions with a HAVING clause but
 without a GROUP BY clause, you cannot directly name columns in
 the select list or HAVING clause.  You can refer to them only as
 function arguments, or in a WHERE clause.

 User Action:  Either make the column named in the message a
 function argument, or if it is in a HAVING clause, change the
 HAVING clause to a WHERE clause.  In general, avoid using HAVING
 without GROUP BY.  Use WHERE instead.

COLNOTNUL

 Column <text>.<text> cannot be UNIQUE because it can contain
 nulls.

 Explanation:  You specified a column using the UNIQUE
 constraint.  The column may contain nulls.  This is not legal
 because two rows cannot contain the NULL values in this column.

 User Action:  Define the named field as NOT NULL.

COLNOTSS

 Column <text> is not a segmented string field

 Explanation:  The column specified in a SEGSTR.CREATE or
 SEGSTR.OPEN statement must be a segmented string field.  This
 column is not.

 User Action:  Specify a column whose datatype is segmented
 string

COLNOTUPD

 Column <text> is not included in the FOR UPDATE clause of cursor
 <text>

 Explanation:  VAX SQL provides the FOR UPDATE clause on a cursor
 definition for DB2 compatablity.  The clause is entirely
 optional.  If a FOR UPDATE clause is specified on the cursor and
 an UPDATE statement that uses the CURRENT OF clause with that
 cursor changes a column which is not one of the columns included
 in the FOR UPDATE clause of the DECLARE CURSOR statement, you
 will get this warning message.

 User Action:  No action is required.  This message will not
 effect the execution of the statement.

COLNOTVAL

 The column CHECK constraint cannot refer to the column <text>

 Explanation:  The CHECK constraint cannot refer to the column
 because the constraint is defined only for a column, not the
 entire table.

 User Action:  Refer to the only that column for which this CHECK
 constraint is being defined or define the CHECK constraint for
 the entire table.

COMTOOLON

 Command line longer than <value> character maximum

 Explanation:  You typed a command line longer than the current
 maximum line length.

 User Action:  Break up the command line with continuation lines.
 There is no practical limit on the total length of all
 continuation lines in a single command.

CONALREXI

 Constraint name <text> on table <text> is already exists in this
 schema

 Explanation:  You requested that a constraint be named with the
 name of an existing constraint.

 User Action:  Choose a different name.

CONAMBIG

 Constraint name <text> was not qualified and is in multiple
 schemas

 Explanation:  You must qualify the constraint name with an
 authorization identifier when accessing more than one schema
 that uses that constraint name.

 User Action:  Make sure the DECLARE SCHEMA statements include
 authorization identifiers and retype the query using the
 appropriate authorization identifier.

CONCHAILL

 Cannot begin program with continuation character

 Explanation:  Apparently the COBOL program starts with a
 continuation character.

 User Action:  Correct the source text and resubmit the job.

CONDICREQ

 Conflicting dictionary requirements

 Explanation:  You specified both the DICTIONARY IS REQUIRED and
 DICTIONARY IS NOT REQUIRED clause in the same ALTER SCHEMA
 statement.

 User Action:  Change the ALTER SCHEMA statement to include only
 one type of DICTIONARY REQUIRED option.

CONNOTDEF

 Constraint <text> is not defined in schema

 Explanation:  The specified constraint does not exist in the
 current schema.

 User Action:  Declare the correct schema.  Check the constraint
 name for correct spelling.  Check the constraint definition to
 make sure you did not specify a term where the constraint name
 was expected.

CONNOTSUP

 <text> is a constant host variable

 Explanation:  You referred to a host variable which was declared
 as a constant.  Constant declarations are not supported.

 User Action:  Either specify the constant as a literal, or use a
 host variable with that value.

CONREAATT

 Conflicting Read Only Attributes

 Explanation:  The user specified both READ ONLY and READ WRITE
 in an  ALTER STORAGE AREA statment.

 User Action:   Decide what is wanted and re-enter the command.

CONSNAATT

 Conflicting snapshot attributes

 Explanation:  CREATE SCHEMA command contained conflicting
 snapshot options.

 User Action:  Either remove the SNAPSHOT DISABLED clause from
 the root file  parameters, or remove the SNAPSHOT clause from
 the storage area       parameters.

CONTPREQ

 P characters must be contiguous in an edit string

 Explanation:  More than one P characters are permitted in an
 edit string, but they must all be contiguous.  This edit string
 contained more than one P characters that are not contiguous.

 User Action:  Make the P characters contiguous.

CONTRIACT

 The trigger actions on trigger <text> and trigger <text>
 conbflict

 Explanation:  You cannot have 2 triggers which will be triggered
 for the        same event on the same table.  These 2 triggers
 would both     be triggered by the same event.

 User Action:  Combine the 2 triggers into a single trigger.

CONVARDEF

 Column qualifier <text> is already defined

 Explanation:  You either specified the same alias more than once
 in a select expression or did not specify an alias in a select
 expression that joins a table with itself.

 User Action:  Either use unique aliases or introduce an alias.

CONVARUND

 Column qualifier <text> is not defined

 Explanation:  You qualified a column name with an alias or table
 not specified in the FROM clause of the select expression.

 User Action:  Make sure the qualifier you used matches an alias
 or table specified in the FROM clause.

CORREFFUN

 Correlated references in functions must not be in expressions

 Explanation:  You cannot use a correlated reference that is part
 of a value expression containing comparison operators, when the
 value expression is itself an argument to a function.  For
 example, SUM(corr_reference + 5).

 User Action:  Reformulate the select expression to avoid using a
 correlated reference in this manner.

CRE_STO_ERR_SCH

 CREATE STORAGE AREA statement only valid as part of a CREATE
 SCHEMA statement

 Explanation:  The CREATE STORAGE AREA statement is only valid as
 part of the    CREATE SCHEMA statement.

 User Action:  Place the CREATE STORAGE statement in the CREATE
 SCHEMA statement.

CS_ERR

 error retrieving collation sequence <text>

 Explanation:  Could not retrieve collating sequence -- see the
 message that follows.

 User Action:  Correct the problem and retry the operation.

CURALROPE

 Cursor <text> was already open

 Explanation:  You opened a cursor that was already open.  An
 implicit close will be done on the cursor and the cursor
 reopened.

 User Action:  None.  This is just a warning.

CURNAMEXI

 Cursor name <text> has already been declared

 Explanation:  You cannot use the same name in more than one
 DECLARE CURSOR statement.

 User Action:  Change the name of this cursor.

CURNOTOPE

 Cursor <text> is not opened

 Explanation:  You named a cursor that was not open in a FETCH
 statement, CLOSE statement, or in the WHERE CURRENT OF clause of
 an UPDATE or DELETE statement.

 User Action:  Issue an OPEN statement for the cursor before
 naming it in any of those statements.  Close the cursor only
 once after opening it.

CUROFNOT

 CURRENT OF cursor-name is allowed only in UPDATE and DELETE
 statements

 Explanation:  The CURRENT OF cursor-name clause is used to
 modify or delete the current record in a cursor.  It has no
 meaning in the WHERE clause of a select expression.

 User Action:  Replace the WHERE CURRENT OF clause with a WHERE
 predicate clause that specifies the record you wish to select.

CUROFSTA

 CURRENT OF clause cannot refer to cursor based on prepared
 statement

 Explanation:  The CURRENT OF clause of an UPDATE or DELETE
 statement specifies a cursor based on a prepared statement.
 Because the prepared statements are generated at run time, you
 cannot precompile UPDATE or DELETE statements that refer to
 cursors based on them.

 User Action:  Use a cursor which is based on an embedded SELECT
 statement (which is known at compile time), or dynamically
 execute the UPDATE or DELETE statement so it can be interpreted
 at run time.

CURTWOOPEN

 Cursor <text> has two open procedures

 Explanation:  There are two open procedures for this cursor.  A
 module can only have one procedure which opens a particular
 cursor.

 User Action:  Remove one of the procedures which opens this
 cursor.  Call the remaining procedure more than one time.

CURUSEINV

 USING clause not allowed for this cursor

 Explanation:  An OPEN or FETCH statement can specify a USING
 clause only for cursors based on a statement named in a PREPARE
 statement.  The cursor specified in this OPEN or FETCH statement
 is not.

 User Action:  Remove the USING clause from the OPEN or FETCH
 statement.

DATCONERR

 Data conversion error

 Explanation:  An error occurred during data conversion.  Refer
 to next message.

 User Action:  The secondary message should clarify the problem.

DATNOTSUP

 Date datatype not supported in this context

 Explanation:  The output of a date value to the language file is
 not supported.

 User Action:  Do not use dates in this manner.

DATTYPUNK

 Data type unknown.  Expression cannot use only host variables

 Explanation:  An assignment or a predicate must have at least
 one database field or literal.

 User Action:  You must use a database variable or literal in the
 expression.

DBHANDUNK

 No DECLARE SCHEMA statement specified an identifier of <text>

 Explanation:  You specified an unknown authorization identifier
 to qualify a table or view name in a select expression.

 User Action:  Check the query and the DECLARE SCHEMA statement
 to make sure the authorization identifiers match.

DBINUSE

 Schema cannot be dropped because it is currently in use.

 Explanation:  You issued a DROP SCHEMA statement, but another
 user had declared the same schema.

 User Action:  Wait for other users to finish with the schema.
 If the schema is in use, however, one would question the wisdom
 of trying to delete it.  Remember that patience is a virtue.

DBKAMBIG

 DBKEY reference is ambigous

 Explanation:  You made an unqualified reference to DBKEY in a
 context        where there is more than one source of a dbkey.

 User Action:  Add a table qualifier to the DBKEY reference.

DBKTOOBIG

 The DBKEY for table <text> is <value> bytes, host variable
 <text> must be the same size or larger.

 Explanation:  The host variable you are using with the DBKEY is
 not the        same size as the dbkey.

 User Action:  Allocate a host variable which is the correct
 size.

DB_EXISTS

 The data dictionary pathname, <text>, chosen for the schema name
 already exists

 Explanation:  The data dictionary path name chosen for the
 schema name already exists in the current directory.

 User Action:  Use another, unique data dictionary path name.

DB_HANDEC

 Handle already declared

 Explanation:  You declared a database handle via ACMS.  This
 interferes with defining a handle through the dynamic interface.

 User Action:  You should not specify another handle.

DB_HANDEC2

 Handle already declared

 Explanation:  You have declared a database handle via ACMS.
 This interferes with defining a handle through the dynamic
 interface.  This also interferes with declaring multiple
 database handles.

 User Action:  You should not specify another handle.

DB_HANLON

 The authorization identifier must be a longword

 Explanation:  Authorization identifiers that are passed from a
 program must be longwords passed by descriptor.

 User Action:  Define the authorization identifier to be a
 longword.  Examples:  For COBOL:  01 AUTHID PIC S9(9) COMP.  For
 FORTRAN:  INTEGER*4 AUTHID.

DB_IN_TXN

 Authorization identifier <text> is already part of this
 transaction

 Explanation:  You specified an authorization identifier twice
 within in the transaction parameters of SET TRANSACTION or
 DECLARE TRANSACTION.

 User Action:  Specify the authorization identifier only once.

DCLBEFEXE

 DECLARE TRANSACTION and DECLARE SCHEMA must be before executable
 statements

 Explanation:  DECLARE TRANSACTION and DECLARE SCHEMA must come
 before the first executable statement in a program.  An
 executable statement is a statement such as SELECT, INSERT,
 UPDATE, OR CREATE.  To avoid this error, put all DECLARE SCHEMA
 and DECLARE TRANSACTION statements in a context file, if
 possible.

 User Action:  Move all DECLARE TRANSACTION statements and
 DECLARE SCHEMA statements before all executable statements.  You
 should specify all DECLARE SCHEMA statements before the first
 DECLARE TRANSACTION statement.

DCLDATBEF

 DECLARE SCHEMA must be before other DECLARE statements

 Explanation:  All DECLARE SCHEMA statements must come before any
 DECLARE CURSOR, DECLARE TRANSACTION, or DECLARE TABLE statements
 in a program.

 User Action:  Move all DECLARE SCHEMA statements before other
 DECLARE statements.

DDLPARAM

 You referred to parameter <text> in a DDL statement

 Explanation:  You specified a parameter in a DDL statement such
 as a   CREATE VIEW or CREATE TRIGGER statement.  This is not
   supported.

 User Action:  Remove the parameter specification.

DECCURINTO

 DECLARE CURSOR statement cannot include an INTO clause

 Explanation:  You specified an INTO clause in the select
 expression in the DECLARE CURSOR statement.  It should go in the
 FETCH statement or in a singleton select statement.

 User Action:  Remove the INTO clause.

DEFCONMOD

 Command line specified default constraint evaluation mode is off

 Explanation:  Your command line specified (either explicitly or
 by default)    that the constraint mode when you start a
 transaction is OFF,    i.e.  that by default, constraints will
 not be evaulated until         a COMMIT is executed.  The ANSI
 and ISO SQL standards require  that the constraint mode when you
 start a transaction be ON,     i.e.  that constraints be
 evaulated at the end of every SQL      statement.

 User Action:  If it is important to have standard behavior in
 your program,  and you have constraints in your database, you
 should specify         the /CONSTRAINT_DEFAULT_MODE=ON in the
 module language command        line or
 /SQLOPTIONS=(CONSTRAINT_DEFAULT_MODE=ON) in the
        precompiler command line.

DEFDBDEC

 A schema has already been declared with the default
 authorization identifier

 Explanation:  You attempted to declare a default schema when
 there already was a default schema.  In interactive SQL, you get
 this error only if you choose not to override the current
 default schema declaration.

 User Action:  Include an authorization identifier which has not
 been declared in the DECLARE SCHEMA statement.

DEFVALINC

 You specified a default value for <text> which is inconsistent
 with its datatype

 Explanation:  The value specified for the value of the default
 value must     have the same type (i.e.  both character, both
 exact numeric,         both aproximate numeric or both dates) as
 the column or domain   it is the default for.  It must also be
 small enough to fit    into column or domain.

 User Action:  Replace the specified value with a value that is
 compatible     with the column.

DEFVALUNS

 Default values are not supported for the datatype of <text>

 Explanation:  You specified a default value for a datatype (such
 as segmented   string) for which defaults are not supported.

 User Action:  Remove the default clause from this definition.

DEGMODSPC

 Only one degree mode may be specified for a transaction

 Explanation:  You specified both concurrency options
 (CONSISTENCY LEVEL 2 and CONSISTENCY LEVEL 3) in a DECLARE
 TRANSACTION statement.

 User Action:  Specify only one option in your DECLARE
 TRANSACTION statement.

DELBACKUP

 EXPORT errors, interchange file deleted

 Explanation:  The export that you were performing could not be
 successfully completed.

 User Action:  Determine why the export failed and correct that
 situation.

DIC_DB_CHG1

 A dictionary definition used by schema <text> has changed

 Explanation:  This database refers to a definition in the
 dictionary that has changed.

 User Action:  Use the INTEGRATE statement to resolve any
 differences.

DIC_DB_CHG2

 Use the INTEGRATE statement to resolve any differences between
 the dictionary and the database

 Explanation:  The data definitions in the data dictionary no
 longer match the definitions in the database file.

 User Action:  Use the INTEGRATE statement to resolve any
 differences.

DIGNUMPIC

 more than 31 digits in a numeric edit string

 Explanation:  The edit string generates more than 31 digits.

 User Action:  Reduce the number of digits in this numeric
 picture string.

DROP_IDX

 Index <text> is also being dropped.

 Explanation:  When you issue the DROP TABLE statement, SQL also
 drops all indexes that use that table.  This message notifies
 you which indices those are.  It is informational only.

 User Action:  None.

DROP_VIEW

 View <text> is also being dropped.

 Explanation:  When you issue the DROP TABLE statement, SQL also
 drops all views that use that table.  This message notifies you
 which views those are.  It is informational only.

 User Action:  None.

DRO_SCH_RDB_ERR

 DROP SCHEMA statement is only supported with Rdb/VMS Version 3.0
 or later

 Explanation:  VAX SQL will not drop    schemas without Version
 3.0 or later of Rdb/VMS        installed on the system.

 User Action:  Install Version 3.0 or later of Rdb/VMS on the
 system.        Alternatively, you can delete the schema by
 deleting       the files at DCL level and from the dictionary by
 using  the dictionary utility.

DTFMTTOOBIG

 Date or time format must be less than 999.

 Explanation:  User entered DATE or TIME value greater than 999
 in the SET DATE FORMAT command.

 User Action:  Enter a value less than or equal to 999.

DTONCEEACH

 DATE or TIME may be specified only once each.

 Explanation:  User entered DATE nnn, DATE nnn or TIME nnn, TIME
 nnn    in the SET DATE FORMAT command.

 User Action:  Enter nothing, DATE, TIME, or one of each, after
 SET DATE FORMAT.

DUPPROCNAM

 <text> is a duplicate procedure name

 Explanation:  There are two procedures in this module with this
 name.

 User Action:  Change the name of one of the procedures.

DUPREFACT

 Duplicate <text> referential action

 Explanation:  You specified 2 update or 2 delete actions on a
 referential    constraint.  This is not supported.

 User Action:  Remove one of the referential actions.

DUPVAR

 Variable <text> is already defined

 Explanation:  You defined a SQL variable for which there was
 already a declaration.

 User Action:  Either use the variable, or specify the name of a
 variable which is not already defined.

DYNSIZARR

 Host variable <text> is an array whose bounds are determined at
 runtime

 Explanation:  The SQL precompilers do not support references to
 arrays whose bounds are determined at run time
 (dynamically-sized arrays).

 User Action:  Assign the value in the dynamically-sized array to
 a field which is not in a dynamically-sized array before using
 it in an SQL statement.

END

 End of input

 Explanation:  No more input was given to SQL.

 User Action:  None.

ENUM_VAR

 Host variable <text> is an enum variable which is illegal in SQL
 statements.

 Explanation:  The named variable is defined as a C enum
 variable.  Such fields are not legal in SQL statements.

 User Action:  Use a different variable.

ERRATTDEC

 Error attaching to declared schema <text>

 Explanation:  A DECLARE SCHEMA statement specified an invalid or
 nonexistent file specification or data dictionary path name.
 See the messages following this message for more information.

 User Action:  Change the DECLARE SCHEMA statement to specify a
 valid file specification or path name.

ERRATTDEF

 Could not use database file specified by SQL$DATABASE

 Explanation:  If you do not issue an explicit DECLARE SCHEMA
 statement, VAX SQL uses the database file specified by the
 logical name SQL$DATABASE.  Because the logical name
 SQL$DATABASE is not defined or does not refer to a valid
 database, SQL could not attach to a database.  See the messages
 following this message for more information.

 User Action:  Explicitly declare a schema before executing any
 statements which require a database, or define the logical name
 SQL$DATABASE to specify the database file you wish to use.

ERRCRESCH

 Error creating schema filename <text>

 Explanation:  There was an error creating the schema.

 User Action:  Correct CREATE SCHEMA statment and retry.

ERRDET

 An error was detected

 Explanation:  This is the exit status for a preprocessor when an
 error was detected.

 User Action:  Correct the error in the host language program and
 resubmit the job to the preprocessor.

ERRINCPATH

 Error including record at pathname "<text>"

 Explanation:  An error was reported trying to include a record
 from the dictionary.

 User Action:  Correct the pathname in the include from
 dictionary statement.

ERRSYMDEL

 Error symbol deleted

 Explanation:  When parsing an SQL statement, the parser
 encountered an error.  The message for that error appeared prior
 to this message.  In an attempt to recover from that error SQL
 deleted the token it found, and generated this message to help
 you understand any additional messages that follow.

 User Action:  None.  This is an informational message only.

ERRSYMREP

 Error symbol replaced by <text>

 Explanation:  When parsing an SQL statement, the parser
 encountered an error.  The message for that error appeared prior
 to this message.  In an attempt to recover from that error, SQL
 replaced the token it found with the specified token, and
 generated this message to help you understand any additional
 messages that follow.

 User Action:  None.  This is an informational message only.

ES_ILL_RPT

 repeat count in edit string is not numeric

 Explanation:  The user specified an edit string that contained a
 repeat count that was not a number, for example, X(9) is legal,
 but X(a) is not.

 User Action:  Specify only numeric values for repeat counts.

EVACLAUNS

 EVALUATING clause ignored

 Explanation:  The DECLARE TRANSACTION statement in SQL does not
 support the EVALUATING clause to specify when the database
 system evaluates constraints.  Constraints are evaluated as
 specified in their definitions.

 User Action:  Issue the DECLARE TRANSACTION statement without
 the EVALUATING clause.

EXESELSTA

 Attempted to EXECUTE a SELECT statement

 Explanation:  You used a prepared SELECT statement in an EXECUTE
 statement.  In dynamic SQL, the only way to process prepared
 SELECT statements is through cursors.

 User Action:  Define a cursor based on the statement you tried
 to execute, and use the cursor in OPEN and FETCH statements.
 Otherwise, use non-SELECT statements only in EXECUTE statements.

EXPNUMLIT

 Expected a numeric literal

 Explanation:  A numeric literal was expected in this context.

 User Action:  Correct the syntax.

EXPQUEXPR

 A query expression was expected

 Explanation:  SQL expected a query expression.  You entered
 something else.

 User Action:  Enter a query expression.

EXTRADATA

 unexpected data at the end of the .RBR file

 Explanation:  Internal error - found more data than expected in
 the Rdb/VMS interchange file (.RBR).

 User Action:  Submit an SPR with a copy of the Rdb/VMS
 interchange file (.RBR) that caused the error.

FETNOTDON

 A fetch has not been done yet for cursor <text>

 Explanation:  You named a cursor in a CURRENT OF clause of an
 UPDATE or DELETE statement but you did not issue a FETCH
 statement for that cursor.

 User Action:  Issue a FETCH statement for the cursor.

FIELD_EXISTS

 Domain <text> already exists in this schema

 Explanation:  You requested that a domain be named with the name
 of an existing type.

 User Action:  Choose a different name.

FLDAMBIG

 Column <text> is not unique in tables in the FROM clause

 Explanation:  The specified column exists in more than one of
 the tables specified in the FROM clause.

 User Action:  Qualify the column name in the select list with
 the table name or an alias.

FLDNOTBCK

 global field <text> not defined as specified

 Explanation:  The base field for a local field is not defined.

 User Action:  This is caused by an inconsistency in the
 database.  Try to recover the missing global field.

FLDNOTCRS

 Column <text> was not found in the tables in current scope

 Explanation:  The specified column does not exist in the tables
 specified in the current scope.

 User Action:  Check the select expression:  you may have
 mistyped the column name or specified the wrong table name or
 alias to qualify the column name.

FLDNOTDEF

 Column <text> is not defined in table <text>

 Explanation:  The specified column does not exist in the table
 specified.

 User Action:  Check the select expression:  you may have
 mistyped the column name or specified the wrong table name or
 alias to qualify the column name.

FLDNOTINREL

 <text> is not a column in table, <text>

 Explanation:  The column you specified is not part of the named
 table.

 User Action:  Check the table definition for the correct column
 name or specify another table.

FLUINPBUF

 Indirect command file buffer flushed for Control C

 Explanation:  You typed Control-C while executing an indirect
 command file.

 User Action:  None.

FORPASLEN

 Host variable <text> is an unsupported passed-length variable

 Explanation:  The host variable declaration uses the FORTRAN
 passed-length (*) feature which is not supported.

 User Action:  Either change the declaration so that only
 supported attributes are used, or move the data to another
 variable which uses only supported attributes.

FUN_VAR

 Host variable <text> is function which is illegal in SQL
 statements.

 Explanation:  The named variable is defined as a C function.
 Functions refnereces are not supported in SQL statements.

 User Action:  Use a different variable.

GARBLED

 interchange file is corrupt

 Explanation:  Internal error - probably mismatched BEGIN and END
 clumps.

 User Action:  Submit an SPR with a copy of the Rdb/VMS
 interchange file (.RBR) that caused the error.

GETCRESEG

 Attempt to get from a created segmented string

 Explanation:  You attempted to do a SEGSTR.GET using a handle
 returned by a SEGSTR.CREATE statement.  You can only do
 SEGSTR.PUTs using the handle returned by create.

 User Action:  Specify the correct handle

GFLOAT

 <text> does not support G_FLOAT

 Explanation:  /G_FLOAT was specified for a language such as
 COBOL which does not support the G_FLOAT datatype.

 User Action:  Unless you are taking the G_FLOAT number and
 passing it to a language which understands G floating numbers,
 you probably want to reprecompile without the /G_FLOAT
 qualifier.  If you use it from this language, the compiled code
 will think it is a different number than the database system
 did.

HEXSTREVE

 A hexadecimal string must have an even number of digits

 Explanation:  A hexadecimal string must have an even number of
 digits.  This is because it takes two hexadecimal digits to
 represent each ASCII character.

 User Action:  Enter a hexadecimal number with an even number of
 digits.

HI_ORD_LOS

 Increasing the scale of column <text> may result in the loss of
 high order digits

 Explanation:  Increasing the scale of a column may result in the
 loss of        significant digits of the data already stored in
 that column.

 User Action:  None.  This is a warning message only.

HVNOTDECL

 Host variable <text> was not declared

 Explanation:  Every host variable that is used in an SQL
 statement in a program must been declared in the host language.

 User Action:  Declare the specified variable using a supported
 declaration.

HV_NOT_IN

 Host variable, <text>, not within scope of BEGIN DECLARE and END
 DECLARE section

 Explanation:  Your program referred to a variable that was
 declared outside of the BEGIN DECLARE and END DECLARE
 statements.

 User Action:  Either move the desired host variable declaration
 to be within this section or remove the BEGIN DECLARE and END
 DECLARE statement.  You can also ignore this warning message.
 BEGIN DECLARE and END DECLARE are only for standard complicance.

IDMISSING

 an authorization ID or a filename is required to create a schema

 Explanation:  The user specified an IMPORT or a CREATE SCHEMA
 statement without specifying an authorization ID or a filename.
 One of is required.

 User Action:  Specify the missing parameter and retry the
 operation.

ILLBEGIN

 file <text> is corrupt or not an Rdb interchange file

 Explanation:  SQL IMPORT can recreate databases only from the
 Rdb/VMS interchange file (.RBR).  This file is not an Rdb/VMS
 interchange file (.RBR).

 User Action:  Retry the operation with the correct file name.

ILLCHAR

 Illegal character detected

 Explanation:  An illegal character has been detected.

 User Action:  Use only valid characters.

ILLDATLEN

 An invalid SQLLEN(<value>) was found for a date field in the
 SQLDA

 Explanation:  You passed in a date column in a SQLDA with a
 SQLLEN that was not 8.

 User Action:  Set the SQLLEN to 8 for date columns in the
 SQLVAR.

ILLEXEIMM

 Illegal EXECUTE IMMEDIATE statement type

 Explanation:  You tried to issue a statement that is not allowed
 in an EXECUTE IMMEDIATE statement (SELECT, DECLARE, OPEN, FETCH,
 CLOSE, PREPARE, DESCRIBE, EXECUTE, INCLUDE, or WHENEVER).

 User Action:  Use PREPARE and a full EXECUTE statement for these
 statements.

ILLFLOLEN

 An invalid SQLLEN(<value>) was found for a FLOAT field in the
 SQLDA

 Explanation:  You passed in an SQLDA with a SQLTYPE FLOAT SQLLEN
 that was invalid.  Only 4, 8, an 16 are legal floating-point
 lengths.

 User Action:  Set the SQLLEN to 4, 8, or 16, depending on the
 length of the floating-point variable passed.

ILLFROM

 CDD definitions may not be included using FROM within CREATE
 SCHEMA

 Explanation:  Use of the FROM <cdd pathname> clause is not
 allowed within a CREATE SCHEMA.

 User Action:  Create the schema first and then include the
 definitions.

ILLHEXNUM

 Illegal hexadecimal number.

 Explanation:  The format of a hexadecimal number is X'ffff',
 where ffff may be up to 16 hexadecimal digits.  A hexadecimal
 digit is a numeric digit (0 to 9) or an A, B, C, D, E, or F.
 The letters may be upper or lower case.  There must be an even
 number of digits.

 User Action:  Enter a proper hexadecimal number.  Make sure that
 the trailing apostrophe is included.

ILLINTLEN

 An invalid SQLLEN(<value>) was found for a integer column in the
 SQLDA

 Explanation:  You passed in an integer column in a SQLDA with a
 SQLLEN that was invalid.  For SQLTYPE of INTEGER, SQLLEN must be
 4.  For SQLTYPE of SMALLINT, SQLLEN must be 2.

 User Action:  Set the SQLLEN to 2 for SMALLINT, or 4 for
 INTEGER.

ILLPICSTR

 illegal character <text> in edit string

 Explanation:  An edit string contained the illegal character
 specified in the message.

 User Action:  Change the edit string to not have that character.

ILLSTRCONT

 Illegal string continuation

 Explanation:  Your program has illegal string continuation.

 User Action:  In COBOL, to continue a string you must do three
 things:  1) not end the string with a quote on the initial line;
 2) insert a continuation character (-) in the first column of
 the next line; and, 3) start the continued string with a quote
 as the first nonblank character after the continuation character
 (this quote is ignored).

IMPL_DIM

 Host variable <text> is defined with an implicit dimension.

 Explanation:  The named variable is defined using the C feature
 of determining the dimension of an array from its
 initialization.  Such variables are not legal in SQL statements.

 User Action:  Define the array variable using an
 explicitly-sized array.

IMP_IDX_CONFLICT

 DEFINE and DELETE INDEX <text> specified

 Explanation:  The user specified a DEFINE and DELETE INDEX using
 the same name.

 User Action:  Specify a either a DEFINE or a DELETE INDEX.

IMP_IDX_TWICE

 DEFINE INDEX <text> specified twice

 Explanation:  The user specified a DEFINE INDEX twice using the
 same name.

 User Action:  Specify a INDEX name only once.

IMP_STO_CONFLICT

 DEFINE and DELETE STORAGE AREA <text> specified

 Explanation:  The user specified a DEFINE and DELETE STORAGE
 AREA using the same name.

 User Action:  Specify a either a DEFINE or a DELETE STORAGE
 AREA.

IMP_STO_MAP_CONFLICT

 DEFINE and DELETE STORAGE MAP <text> specified

 Explanation:  The user specified a DEFINE and DELETE STORAGE MAP
 using the same name.

 User Action:  Specify a either a DEFINE or a DELETE STORAGE
 AREA.

IMP_STO_MAP_TWICE

 DEFINE STORAGE MAP <text> specified twice

 Explanation:  The user specified a DEFINE STORAGE MAP twice
 using the same name.

 User Action:  Specify a STORAGE MAP name only once.

IMP_STO_TWICE

 DEFINE STORAGE AREA <text> specified twice

 Explanation:  The user specified a DEFINE STORAGE AREA twice
 using the same name.

 User Action:  Specify a STORAGE AREA name only once.

INCNOTREC

 <text> is not a dictionary record definition

 Explanation:  The data dictionary path name in an INCLUDE FROM
 DICTIONARY statement must specify a dictionary record
 definition.  The dictionary object specified is not a record
 definition.

 User Action:  Change the path name to the path name for a record
 definition, or remove the INCLUDE statement.

INC_DAT_TYP

 Altering column <text> to an incompatible datatype may cause
 data loss

 Explanation:  Altering a column to a datatype that is
 incompatible with the  old datatype might cause data already
 stored in that column  to appear lost.

 User Action:  None.  This is a warning message only.

INDEXTS

 There is another index named, <text>, in this schema

 Explanation:  The index name you tried to define already exists.

 User Action:  Try another index name.

INDFIXINT

 Indicator variable <text> is not an unscaled fixed numeric

 Explanation:  Indicator variables be declared as the host
 language equivalent of an unscaled integer data type.

 User Action:  Declare the indicator variable as an unscaled
 integer host variable.

INDNOTDEF

 Index <text> is not defined in schema

 Explanation:  The specified index does not exist in the current
 schema.

 User Action:  Declare the proper schema.  Spell the index name
 correctly.  You may have specified an expression where an index
 name was expected.

INDSHOINT

 Indicator variable <text> is not a SMALLINT

 Explanation:  Indicator variables in the dynamic interface
 should be declared as the host language equivalent a SMALLINT
 data type.

 User Action:  In COBOL, declare indicator variables as PIC S9(4)
 COMP.  In FORTRAN, declare indicator variables as INTEGER*2.  In
 PL/I, declare indicator variables as FIXED(15) BINARY.

IND_EXISTS

 Index <text> already exists in this schema

 Explanation:  You attempted to create an index with the name of
 an existing index

 User Action:  In the precompiler and module language, this is
 just a warning.  If the index exists when you execute the
 statement, you will get a fatal error.  If you expect to drop
 the index before you execute this statement, then you do not
 need to make any changes.  In interactive, dynamic and runtime
 for precompiled and module language programs, this is a fatal
 error.  You must choose a different name.

INSCOLALR

 Column <text> appears more than once in the INSERT column list

 Explanation:  You specified the same column name more than once
 in an INSERT statement.  Columns can only appear once.

 User Action:  Remove one occurrence of all columns which appear
 more than once.

INTIGNSYS

 Interval option ignored for system relation area

 Explanation:  The storage area that contain the system relations
 must   have UNIFORM page formats.  Either through the use of the
 defaults, or by directly specifing the INTERVAL option,
        SQL has been told to apply the INTERVAL option for the
 area   containing the system relations.  SQL is ignoring that
  option.

 User Action:  Nothing.  This is an informational message.  The
 user might     want to change the command if it originated in a
 command        file.  This may avoid confusion later.

INTNOTSYS

 Interval option not valid for system relation area

 Explanation:  The storage area for RDB$SYSTEM was defined to
 have the       interval option.  This is not allowed for
 RDB$SYSTEM.

 User Action:  Remove the interval option from the command and
 try again.

INTVALLOW

 Interval value must be at least 256

 Explanation:  The specified interval value for space management
 pages is       too small.  The minimum value is 256 pages.

 User Action:  Change the interval value for space management
 pages on the   CREATE SCHEMA statement to a legal value.

INTVALOVR

 Interval value overwritten to 256 pages

 Explanation:  The specified interval value for space management
 pages is       too small.  The minimum value is 256 pages.  VAX
 SQL overwrote  the specified value with 256.

 User Action:  Change the interval value for space management
 pages on the   CREATE SCHEMA statement to a legal value.

INVACL

 Invalid Access Control List entry

 Explanation:  The syntax of the access control list entry string
 is not valid.

 User Action:  Correct the syntax of the access control list
 entry.

INVARRSUB

 Host variable <text> defined with illegal use of subscripts

 Explanation:  The named host variable uses subscripts in a way
 that is illegal for the C compiler.  Most likely the use is
 through a typedef that is defined as an array.

 User Action:  Use a different variable or redefine the type
 structure of the program.

INVCHAINP

 Invalid character in input

 Explanation:  The input contains an illegal or unrecognizable
 character.

 User Action:  Correct the source text and resubmit the job.

INVCHANUMSTR

 Invalid character in numeric string

 Explanation:  The string appears to be a numeric literal.
 However, it contains one or more illegal characters.

 User Action:  Correct the source text and resubmit the job.

INVCOLLST

 column list in view definition contains the wrong number of
 names

 Explanation:  The list of column names you specified in a view
 definition contained a different number of names than the number
 of value expressions in the select list of the definition's
 SELECT expression.  There must be a strict one-to-one
 correspondence between the two lists.

 User Action:  Specify the same number of column names in the
 column list as value expressions in the select list.

INVCOLSPC

 Column names must be qualified by table names.

 Explanation:  You must qualify the column name in a COMMENT ON
 COLUMN statement with a table name.

 User Action:  Specify the column name as
 <table-name>.<column-name>.

INVCOMLIN

 Invalid command line

 Explanation:  You specified extra parameters or invalid command
 line syntax in a module language compiler command line.

 User Action:  Specify only supported command line options.

INVCONS

 unable to import constraint <text>

 Explanation:  Internal error - the named constraint will not
 appear in the recreated database.

 User Action:  Submit an SPR with a copy of the Rdb/VMS
 interchange file (.RBR) that caused the error.  In the meantime,
 you can redefine this constraint explicitly.

INVCORRSL

 Invalid select list in a UNION CORRESPONDING query

 Explanation:  There are 2 columns in one of the select lists
 being used     in the UNION CORRESPONDING query expression with
 the same       name.  This is not supported if there is a column
 in the other   select list with that name as well.

 User Action:  Either remove one of the columns with the same
 name from the  select list, or match columns to be combined in
 the UNION      by position rather than name.

INVDATCON

 Invalid conversion between DATE column <text> and host variable
 <text>

 Explanation:  Only binary dates can be compared or assigned to
 or from DATE columns.

 User Action:  Use a date declaration for the host variable to be
 used with the date field:  in COBOL, use S9(11)V9(7) COMP; in
 PL/I, use CHAR(8) or BYTE_FIELD(8); in FORTRAN, use CHARACTER*8.

INVDBKREF

 Invalid DBKEY reference

 Explanation:  You can refer to dbkeys only on the right hand
 side of an     assignment or in an equals Boolean.

 User Action:  Remove the invalid dbkey reference.

INVDISXPR

 Invalid DISTINCT expression

 Explanation:  In a function specification, if DISTINCT is
 specified, the value expression must be just a column name.  You
 specified a value expression other than a column name in a
 function with the DISTINCT clause, such as SUM(DISTINCT
 SALARY_AMOUNT * .10).

 User Action:  Change the value expression to a column name or
 remove the DISTINCT clause.

INVESCVAL

 Invalid escape clause value

 Explanation:  The value specified in the escape clause of a like
 predicate      must be a single character string value.

 User Action:  Specify a valid value expression in the escape
 clause

INVFLD

 unable to import field <text>

 Explanation:  Internal error - the named field will not appear
 in the recreated database.

 User Action:  Submit an SPR with a copy of the Rdb/VMS
 interchange file (.RBR) that caused the error.

INVFUNREF

 Invalid function reference

 Explanation:  You cannot include in the WHERE clause (or in any
 subqueries of the WHERE clause) functions that use columns of
 tables in the FROM clause as their argument.

 User Action:  Change your select expression to eliminate
 functions with this type of argument.

INVHVDECL

 Host variable <text> was invalidly declared.

 Explanation:  Every host variable that is used in an SQL
 statement in a program must be declared in the host language
 using the supported subset of declaration syntax for the
 language.  Not using the supported subset causes this error.
 Another way this message can be generated is to use an indicator
 variable that is not a signed word (for example, in COBOL:  PIC
 S9(4) COMP).

 User Action:  Use host variable declaration syntax for this
 variable that is supported by SQL.

INVINDEX

 unable to import index <text>

 Explanation:  Internal error - the named index will not appear
 in the recreated database.

 User Action:  Submit an SPR with a copy of the Rdb/VMS
 interchange file (.RBR) that caused the error.  In the meantime,
 you can recreate this index explicitly.

INVLENHV

 Only a numeric variable may be used receive the length

 Explanation:  You used a variable which was not numeric.  This
 is not supported.

 User Action:  Either ommit the argument to receive the length,
 or use a numeric

INVNUMLIT

 <text> is an invalid numeric literal

 Explanation:  An invalid numeric literal was specified which
 could not be converted to a numeric value.  This is usually
 because it is to big to fit into any VAX data type without
 losing significance.

 User Action:  Change the literal to be a valid numeric literal.

INVOBJFIL

 Invalid object file <text> specified

 Explanation:  SQL uses the same directory specification and file
 name for any files it creates (such as the language files) as
 that specified in the /OBJECT qualifier on the command line.
 You specified a nonexistent or invalid file specification
       for the /OBJECT qualifier.

 User Action:  Use a valid object file specification with the
 /OBJECT qualifier.

INVORDNUM

 ORDER BY number is less than 1 or exceeds count of select-list
 items

 Explanation:  The number in the ORDER BY clause, used to specify
 which expression from the select list to sort by, is bigger than
 the number of items in the select list or it is below 1.

 User Action:  Use a number which corresponds to an item in the
 sort list.

INVPRIV

 Invalid privilege for this object

 Explanation:  You used the ENTRY keyword with the GRANT
 statement.  ENTRY is supported for REVOKE only.  Or, a GRANT or
 REVOKE statement specified for a schema a privilege which is
 valid only for tables, or specified for a table a privilege
 which is valid only for a schema.

 User Action:  Do not use ENTRY with GRANT.  Or, make sure that
 the privileges you specify in GRANT or REVOKE are valid for the
 object (schema or table) named.

INVQUAL

 Invalid qualifier <text> specified on command line

 Explanation:  You specified invalid command qualifiers in a
 module language compiler command line.

 User Action:  Specify only supported command line qualifiers

INVREFCLA

 Invalid referencing clause

 Explanation:  You specified a referencing clause on a trigger
 which is not   for update.  The referncing clause is only valid
 if the trigger         is invoked on updates.

 User Action:  Remove the referencing clause.

INVRELVIEW

 unable to import table or view <text>

 Explanation:  Internal error - the named relation or view (and
 its data) has been lost.

 User Action:  Submit an SPR with a copy of the Rdb/VMS
 interchange file (.RBR) that caused the error.

INVSELLIS

 Select list cannot mix columns and functions without GROUP BY

 Explanation:  The select list in a select expression without a
 GROUP BY clause cannot include both functions and column
 references which are not in functions.

 User Action:  Either add a GROUP BY clause, remove the function
 references, or remove the column references that are not in
 functions.

INVSELSTAR

 * is not allowed in this context

 Explanation:  You specified a column wildcard (* or p.*) in a
 context where wildcards are not supported, such as outside a
 select list or in a select list for a select expression
 containing a HAVING clause but no GROUP BY (in such a case, you
 cannot specify columns, either, unless they are an argument to a
 function).

 User Action:  Replace the wildcard with the column name you want
 to use.

INVSQLCODE

 SQLCODE has an invalid data type

 Explanation:  SQLCODE must be declared as a signed longword.
 The declaration of SQLCODE in this program is a different data
 type.

 User Action:  Change the data type of SQLCODE.

INVSSCONV

 Invalid conversion for segmented string column <text>

 Explanation:  You attempted to do an assignment using a
 segmented string.

 User Action:  Do not use segmented strings.

INVSSHAN

 Invalid segmented string handle

 Explanation:  the host variable supplied to hold a segmented
 string handle must be at least 4 bytes long.

 User Action:  Specify a larger host variable.

INVTRG

 unable to IMPORT trigger <text>

 Explanation:  Internal error - the named trigger will not appear
 in the recreated database.

 User Action:  Submit an SPR with a copy of the Rdb/VMS
 interchange file (.RBR) that caused the error.  In the meantime,
 you can redefine this trigger explicitly.

INVTRISTMT

 Invalid triggered statement

 Explanation:  You specified a statement or clause in a triggered
 statement      list which is not supported.  Examples of such
 statements are:         1)     any statement other than an
 delete, insert, update,                rollback or error
 statement.      2)     a where current of clause in and update
 or delete              statement.       3)     a returning
 clause on an insert statement.

 User Action:  Remove the invalid statement or clause

INVTYPE

 Host variable <text> is based on an invalid type

 Explanation:  The host variable you referred to is based on a
 type which is either not a supported type definition or was
 invalidally declared.

 User Action:  Use a different type defintion.

INVVALLIS

 The value list must have as many items as the column list

 Explanation:  An INSERT statement must have as many values in
 the value list as there are in the column list.  You specified
 the wrong number of items.  Note that if there are any host
 structures in the value list, they will be expanded to include
 their elementary items.  In that case, to get the number of
 items in the value list, you must count the elementary items for
 all the host variables.

 User Action:  Enter the correct number of values.

IOERROR

 an unexpected I/O error occurred

 Explanation:  Unable to read any more of the Rdb/VMS interchange
 file (.RBR); part of the database may be imported.

 User Action:  Correct the problem indicated by the message that
 follows this message and retry the operation.

ISQLINTO

 Interactive SQL does not support the INTO clause in SELECT or
 FETCH

 Explanation:  SELECT and FETCH statements in interactive SQL
 cannot include INTO clauses, since interactive SQL does not
 support host variables.

 User Action:  Enter the statement again, without the INTO
 clause, to display the values on the terminal.

JUNONLIN

 Extraneous characters found after the end of the statement

 Explanation:  You typed extra characters after the end of the
 statement.

 User Action:  Check statement syntax for correct statement
 termination.

KEYTOIDENT

 Nonstandard -- a keyword was used as an identifier

 Explanation:  You specified an SQL keyword in a place where it
 is not         a valid keyword, but where an identifier may be
 specified.     The keyword will be used as an identifier.

 User Action:  None, this is an informational message.  However,
 note that      you will not be able to specify this identifier
 in any context         where the keyword may appear.

LANFILEXT

 <text> is the language file extension, please use another
 extension

 Explanation:  The input file type you specified to the
 precompiler is the same file type as the output file type.

 User Action:  Rename the file with the default file
 specifications and run the precompiler again.  Refer to the
 default file specifications in the VAX SQL User's Guide.

LANSWIVAL

 Value not allowed on the language qualifier

 Explanation:  The SQL precompiler requires a language qualifier
 (such as /COBOL) to specify the host language.  However, you
 specified a value with that qualifier (such as COBOL=3), which
 is not allowed.

 User Action:  Remove the value from the language qualifier.

LANUNSDTP

 <text> does not support the datatype for parameter <text>

 Explanation:  The language specified in the LANGUAGE clause of
 the module does not support the datatype specified for this
 parameter.

 User Action:  If you did not intend to use a datatype the
 language does not support, change the datatype to one the
 language supports.  If you know the language does not support
 the datatype, you can use it anyway.  This is is only a warning
 message.

LENMISMAT

 Truncating right hand side string for assignment to column
 <text>

 Explanation:  You executed an INSERT or UPDATE statement, and
 the string you assigned to a text column is longer than the
 column's definition.

 User Action:  The message is just a warning.  You can issue an
 UPDATE statement to change the value stored or a ROLLBACK
 statement to terminate the transaction and cancel the INSERT
 operation.

LOOK_FOR

 Syntax error, looking for <text>, found <text> instead

 Explanation:  The syntax expected a specific keyword, but you
 entered another.

 User Action:  Check the syntax and reenter the correct keyword.

LOOK_FOR_CON

 <text>

 Explanation:  This message lists syntactically legitimate
 alternatives.

 User Action:  Consider options from the list.

LOOK_FOR_FIN

 found <text> instead

 Explanation:  Last of three messages generated by syntax errors,
 this message shows the invalid syntax that SQL encountered.

 User Action:  Reenter the statement, or use EDIT to correct it.

LOOK_FOR_STMT

 Syntax error, looking for a valid SQL statement, found <text>
 instead

 Explanation:  SQL did not find the beginning of a statement
 where it expected one.

 User Action:  Supply a valid statement.

LOOK_FOR_STT

 Syntax error, looking for:

 Explanation:  The syntax expected one of several valid
 possibilities, list follows.

 User Action:  Consider options from the list in the next
 message.

LOOK_FOR_UNTERM

 Syntax error, looking for <text>, found <text> instead

 Explanation:  This is issued with a SQL-F-BUGCHK because it
 indicates that a severe error has occurred in the syntax tables.

 User Action:  Record the exact command line as typed, (use EDIT
 to write it to a file) and submit an SPR.  Then consider finding
 a workaround.

LOW_ORD_LOS

 Reducing the scale of column <text> may result in the loss low
 order precision

 Explanation:  Altering the scale of a column may result in the
 perceived loss         of data stored in that column due to
 rounding.

 User Action:  None.  This is a warning message.

MAXFLDPRTSTR

 Maximum number of columns for table in SELECT * is <value>

 Explanation:  You used the column wildcard (*) in the select
 list for a table that has too many columns.

 User Action:  Name a subset of the columns explicitly in the
 select expression.

MAXNESEXC

 Maximum allowed statement nesting level exceeded

 Explanation:  You exceeded the maximum allowed nesting of
 subqueries.

 User Action:  Reduce the nesting level.

MAXRELEXC

 Maximum number of tables allowed in SELECT exceeded

 Explanation:  You exceeded the maximum number of tables allowed
 in the FROM clause of a select expression.

 User Action:  Reduce the number of tables named in the FROM
 clause.

MISREQVAL

 <text> must have a value

 Explanation:  No value was specified for a qualifier that was
 which must have a value.

 User Action:  Correct the command line syntax error, specifying
 a value for the qualifier.

MULDIMARR

 Host variable <text> is a multi-dimensioned array

 Explanation:  The SQL precompilers do not support references to
 multi-dimensioned arrays.

 User Action:  Assign the value in the multi-dimensioned array to
 a field which is not in a multi-dimensioned array before using
 it in an SQL statement.

MULSPECATR

 Attribute is specified redundantly

 Explanation:  You specified a field attribute more than once.
 Because SQL can not determine which attribute to use, it rejects
 it.

 User Action:  Respecify the definition without the redundant
 clauses.

MULTSPECATR

 Multiple specified attribute.  "<text>" was specified more than
 once

 Explanation:  An attribute was specified more than once in a
 conflicting manner.

 User Action:  Remove conflicts and try the statement again.

MULT_STRUCT

 Host variable <text> is based on a structure defined more than
 once.

 Explanation:  The named host variable is based on a structure
 that is defined more than once in the file being precompiled.
 Either the user defined the structure more than once in a single
 C procedure (which is illegal in any C program), or there is
 more than one procedure that defines the structure (legal in C,
 but the SQL C precompiler does not recognize that the structures
 are in two different procedures and generates this error).

MUL_UIC

 Multiple UIC in ACL entry

 Explanation:  You used more than one user identification code
 (UIC) in an ACL entry.

 User Action:  Use only one UIC in ACL entry.

NAMCONF

 the database pathname <text> is the same as another dictionary
 entity

 Explanation:  The name chosen for the database is the same as
 another dictionary entity of a different type.

 User Action:  Choose a different name.

NAMTOOBIG

 The name <text> is longer than the <value> character maximum

 Explanation:  You specified a name which is longer than the
 maximum supported length for names in this context.

 User Action:  Use a shorter name.

NEG_DIM

 Host variable <text> has a negative dimension.

 Explanation:  The size of this array is less than or equal to
 zero.

 User Action:  Only use positive dimensions.

NESFUNINV

 Functions may not be nested

 Explanation:  Functions cannot contain other functions in their
 arguments.  For example, AVG(COUNT(DISTINCT(CITY)) is illegal.

 User Action:  Do not nest functions.

NESINCFIL

 Cannot include file <text> from another included file

 Explanation:  You attempted to nest INCLUDE file-spec
 statements.  Source code files specified in an INCLUDE file-spec
 statement cannot themselves contain nested INCLUDE file-spec
 statements.

 User Action:  Move the INCLUDE statement to the main program.

NESQRYEXP

 Column select expression was expected

 Explanation:  You supplied something besides a column select
 expression where SQL expected one.

 User Action:  Correct the syntax error.

NOALTER

 No attributes specified for ALTER <text>

 Explanation:  The user specified an ALTER DOMAIN statement or an
 ALTER TABLE ALTER column-name clause without specifying any
 attributes.

 User Action:  Specify something to change.

NOBATUPD

 BATCH_UPDATE is not supported in VAX SQL

 Explanation:  A DECLARE TRANSACTION statement specified the
 BATCH_UPDATE transaction mode.  VAX SQL does not support
 BATCH_UPDATE.

 User Action:  Replace BATCH_UPDATE with READ_WRITE reserving the
 tables you want to update with EXCLUSIVE WRITE locking.

NOBCKFIL

 export file <text> not created

 Explanation:  An error has occurred during creation of the
 EXPORT file.

 User Action:  Follow actions directed by the corresponding RMS
 error.

NOBCKTRNS

 you cannot EXPORT a database from within a transaction

 Explanation:  You typed EXPORT from inside a transaction.

 User Action:  End the transaction and try again.

NOCDD

 There is no data dictionary on this system.  Specify FILENAME in
 the DECLARE SCHEMA statement

 Explanation:  You declared a schema with a data dictionary path
 name, but there is no data dictionary running on this system.
 You must declare a schema using a file name.

 User Action:  Declare the schema with the database file name.

NOCDDALT

 There is no data dictionary on this system.  Specify FILENAME in
 the ALTER SCHEMA statement

 Explanation:  You altered a schema with a data dictionary path
 name, but there is no data dictionary running on this system.
 You must alter a schema using a file name.

 User Action:  Alter the schema with the database file name.

NOCDDRES

 the CDD will not be updated

 Explanation:  You cannot store the database information in the
 CDD.  See the following message.

 User Action:  Correct the problem and retry the operation.

NOCDDUPDAT

 Schema invoked by filename, the data dictionary will not be
 updated

 Explanation:  You issued a data definition statement after
 invoking by file name

 User Action:  This is a warning.  You can ROLLBACK and invoke
 the schema by specifying the path name.  This ensures that data
 definitions are updated both in the data dictionary and in the
 schema itself.

NOCMPBYRES

 computed field <text> in relation <text> not imported

 Explanation:  You specified a computed field in your database
 that could not be imported.  Perhaps the field references other
 fields and relations that were deleted from the database by an
 older version of the software that would have permitted such a
 thing.

 User Action:  You must investigate the problem further.  The
 table should have been properly imported except for the listed
 column.

NOCOLALL

 <text> interpreted as column name where none are allowed

 Explanation:  An expression included a string SQL interpreted as
 a column name where a column name does not make sense.  For
 example, specifying a column name in the VALUES clause of an
 INSERT statement generates this error.  Or, omitting quotes
 around a string literal can also generate this error.

 User Action:  Replace the string with a quoted literal or host
 variable, or use a different form of the statement which will
 allow column names.

NOCOLNAM

 This view definition must explicitly list column names

 Explanation:  You must specify names for all the columns in a
 view if the select expression in the view definition uses
 statistical functions or arithmetic expressions to create
 columns not in the source tables.

 User Action:  Explicitly name each coulumn in the view
 definition.

NOCONNAM

 Cannot create <text> constraint name for table <text>

 Explanation:  SQL tried to create a unique name for a CHECK type
 constraint on the named table.  SQL could not generate a unique
 name for this table.

 User Action:  You can either delete all CHECK constraints for
 this table and then recreate all of the constraints or you can
 specify the DIAGNOSTIC parameter to give the constraint an
 explicit name.

NOCONRES

 unable to import constraint <text>

 Explanation:  Could not import this constraint -- see the
 message that follows.

 User Action:  Correct the problem and retry the operation.

NOCORRCOL

 There are no matching columns in the corresponding select lists

 Explanation:  You specified a UNION CORRESPONING query
 expression in which there were no corresponding columns in the 2
 select lists.  There must be at least one column which matches.

 User Action:  Either ommit the CORRESPONDING keyword, or specify
 at least one pair of columns which match.

NODATDIV

 No DATA DIVISION found in COBOL program.

 Explanation:  Every COBOL program that uses embedded SQL must
 have a DATA DIVISION statement.  None was found in your input
 file.

 User Action:  Add a DATA DIVISION statement to your program.

NODATRES

 remaining data for this relation will be ignored

 Explanation:  An error occurred while you attempted to store the
 data; see the following message.

 User Action:  Correct the problem and retry the operation.

NODBKGRO

 There is no DBKEY for a row in a result table with a GROUP BY

 Explanation:  A SELECT expression with a group by clause
 requested the  DBKEY.  There is no DBKEY for a row in a grouped
 table.

 User Action:  Remove the DBKEY reference.

NODBNAME

 A schema name was not specified on a DECLARE SCHEMA statement

 Explanation:  You issued a DECLARE SCHEMA statement that did not
 specify a schema by file specification or data dictionary path
 name.

 User Action:  Check the syntax of the DECLARE SCHEMA statement.

NODEFDB

 There is no default authorization identifier

 Explanation:  You specified a table name without an
 authorization identifier but there is no default authorization
 identifier.

 User Action:  Either declare a default authorization identifier,
 or include the authorization identifier for a schema you have
 declared in the table name.

NOFILLIST

 SQL does not support lists of files

 Explanation:  You specified a list of module language files on
 the module language command line, or a list of context files on
 the precompiler command line.  SQL does not support lists of
 files.

 User Action:  Specify only one language file and one context
 file on a command line.

NOFLDRES

 unable to import domain <text>

 Explanation:  Could not import this domain.  See the following
 message.

 User Action:  Correct the problem and retry the operation.

NOIDXRES

 unable to import index <text>

 Explanation:  Could not import this index.  See the following
 message.

 User Action:  Correct the problem and retry the operation.

NOINCDIC

 The INCLUDE FROM DICTIONARY statement is not supported in <text>

 Explanation:  The include from dictionary statement is not
 supported for  langauages which do not have an equivalent
 statement in the       language.  An example of this is Ada.

 User Action:  Remove the include from dictionary statement.

NOITEMDEF

 unable to define item from command line

 Explanation:  Could not define an item from the command line.
 See the following message.

 User Action:  Correct the problem and retry the operation.

NOLANGFIL

 No input file specified

 Explanation:  You did not specify a file for the precompiler.

 User Action:  Enter the precompiler command line again,
 specifying a file this time.

NOMAPRES

 unable to import storage map <text>

 Explanation:  Could not import this storage map.  See the
 following message.

 User Action:  Correct the problem and retry the operation.

NOMATCHKEY

 There is not a matching UNIQUE or PRIMARY KEY constraint for
 <text>

 Explanation:  You specified a referenced column list which does
 not match      the columns specified as the key for any UNIQUE
 or PRIMARY KEY         constraint.  The referenced column list
 must be an exact match         for the key of such a constraint.

 User Action:  Specify a referenced column list that matches a
 key for a      UNIQUE or PRIMARY KEY column, or define a UNIQUE
 or PRIMARY     KEY constraint that matches the referenced column
 list you       specified.

NOMODFIL

 No module file specified on command line

 Explanation:  A module language compiler command line must
 include the name of a module file to compile.  This command line
 did not.

 User Action:  Repeat the command line with the name of a module
 file you wish to compile.

NONOVAL

 Negated qualifiers may not have values

 Explanation:  You specified a value for a qualifier that was
 preceded by NO.

 User Action:  Correct the command line syntax error, removing NO
 or the value.

NONSTAAMB

 This host variable is ambiguous in the host file

 Explanation:  The ANSI and ISO SQL standards require that host
 variable       names be unique in the entire file being
 preprocessed.          VAX SQL only requires it to be unique in
 its language scope.    This host variable is not unique in the
 file.

 User Action:  If it is important to have only standard features
 in your        program, you should change the name of this host
 variable       to make it unique in the file.

NONSTACAS

 Nonstandard use of lower case

 Explanation:  This token contains lower case characters.  The
 ANSI and ISO   SQL standards only supports lower case in quoted
 strings.

 User Action:  If it is important to have only standard syntax in
 your   program, you should remove this syntax.

NONSTACOB

 COBOL file is not ANSI format

 Explanation:  The file being processed by the SQL COBOL
 precompiler is not     in ANSI format, or, if it is in ANSI
 format, you did not    specified the /ANSI switch.  The ANSI and
 ISO SQL standards      require that all precompiled COBOL
 programs be in ANSI format.

 User Action:  If it is important to have your program in a
 standard format,       you should convert your program to ANSI
 format.        See the VAX COBOL Reference Manual for a
 definition of what     ANSI and TERMINAL formats are and how to
 convert between them.

NONSTACOL

 Column <text> has a nonstandard datatype

 Explanation:  You referenced a column whose datatype is not
 included       in the ANSI and ISO SQL standards.

 User Action:  If it is important to have only standard features
 in your        program, you should change the datatypes of these
 columns        to be an standard datatype.

NONSTACON

 The standard does not permit this datatype conversion

 Explanation:  You are comparing, assigning or unioning to
 expressions with       different datatypes.  These two
 expressions must be converted  to a common datatype.  The ANSI
 and ISO SQL standards do       not support this conversion.

 User Action:  If it is important to have only standard features
 in your        program, you should change your statement to use
 supported      conversions.

NONSTACUC

 The standard requires columns UNIONed together be identical

 Explanation:  The ANSI and ISO SQL standards require that
 columns which  are being merged into a single result column by a
 UNION must     have identical definitions, i.e.  they must have
 the same       datatype, length, scale etc.  The column pointed
 to is not      identical with the column it is being merged
 with.

 User Action:  If it is important to have only standard features
 in your        program, you should change the datatypes of these
 columns        to be identical, or remove the UNION from your
 program.

NONSTADIS

 The standard only permits one DISTINCT in a select expression

 Explanation:  You have a select expression which either has 2
 functions with         DISTINCT clauses, or has a DISTINCT
 clause for the entire  select list and a DISTINCT in a function.
 The ANSI and ISO       SQL standards do not support multiple
 disctinct clauses.

 User Action:  If it is important to have only standard features
 in your        program, you should remove one of the distinct
 clauses.

NONSTADTP

 Nonstandard datatype

 Explanation:  The datatype indicated or the datatype of the
 column indicate        is not included in the current ANSI and
 ISO standards for SQL.

 User Action:  If it is important to have only standard syntax in
 your   program, you should remove this syntax.

NONSTADYN

 The SQL standard does not include the dynamic interface

 Explanation:  The syntax indicated is not included in the
 current ANSI and       ISO standards for SQL.  The standard does
 not define the         dynamic interface.

 User Action:  If it is important to have only standard syntax in
 your   program, you should remove this syntax.

NONSTAHV

 This host variable has a nonstandard declaration

 Explanation:  The ANSI and ISO SQL standards only require that a
 small subset of host language data declarations be
     supported.  The declaration for this host variable
         uses language features which the standards do not
 require.

 User Action:  If it is important to have only standard features
 in your        program, you should change the definition of this
 host   variable.

NONSTANAM

 Nonstandard name

 Explanation:  This name is not a valid name in the ANSI and ISO
 SQL    standards.  It is either longer than 18 characters
      or contains a $.

 User Action:  If it is important to have only standard syntax in
 your   program, you should remove this syntax.

NONSTAOKW

 Nonstandard syntax -- required keyword or clause ommitted

 Explanation:  The syntax indicated is not included in the
 current ANSI and       ISO standards for SQL.  The standard
 requires a clause or   keyword which is optional in VAX SQL.
 You have ommitted that         clause or keyword.

 User Action:  If it is important to have only standard syntax in
 your   program, you should remove this syntax.

NONSTAPHY

 The SQL standard does not specify the physical schema

 Explanation:  The syntax indicated is not included in the
 current ANSI and       ISO standards for SQL.  The standard does
 not define physical    objects.

 User Action:  If it is important to have only standard syntax in
 your   program, you should remove this syntax.

NONSTAQUO

 Nonstandard quote character

 Explanation:  The ANSI and ISO SQL standards require the ' quote
 character.     You used the " quote character.  Or, ANSI
 requires continuation  be done by language rules, which in COBOL
 means the first        character on the line being continued
 must be a ".  You used         an '.

 User Action:  If it is important to have only standard syntax in
 your   program, you should remove this syntax.

NONSTASM

 The SQL standard does not include schema manipulation

 Explanation:  The syntax indicated is not included in the
 current ANSI and       ISO standards for SQL.  The standard does
 not define the         schema manipulation language.

 User Action:  If it is important to have only standard syntax in
 your   program, you should remove this syntax.

NONSTASYN

 Nonstandard syntax

 Explanation:  The syntax indicated is not included in the
 current ANSI and       ISO standards for SQL.

 User Action:  If it is important to have only standard syntax in
 your   program, you should remove this syntax.

NONSTATXN

 The SQL standard does not specify how to control transaction
 characteristics

 Explanation:  The syntax indicated is not included in the
 current ANSI and       ISO standards for SQL.  The standard does
 not specify how        transaction characteristics are to be
 defined.

 User Action:  If it is important to have only standard syntax in
 your   program, you should remove this syntax.

NONSTAUNI

 The standard only permits UNION outside of subqueries in DECLARE
 CURSOR

 Explanation:  You have included a UNION in a context in which
 the ANSI       and ISO SQL standards do not support.  Only
 DECLARE CURSOR         statements may have a UNION in the
 standard.

 User Action:  If it is important to have only standard features
 in your        program, you should remove this UNION clause.

NONSTAVIA

 Nonstandard feature for integration with other Digital products

 Explanation:  The syntax indicated is not included in the
 current ANSI and       ISO standards for SQL.  This is a feature
 which is provided      for compatability with other Digital
 products such as       Datatrieve and CDD/Plus.

 User Action:  If it is important to have only standard syntax in
 your   program, you should remove this syntax.

NOOPENCUR

 There is no OPEN procedure for cursor <text>

 Explanation:  There are no OPEN procedures for this cursor.  A
 module must have exactly one procedure which opens a particular
 cursor.

 User Action:  Add a procedure which opens this cursor.

NOPRECOMPSEL

 No precompiler selected

 Explanation:  You invoked the precompiler without specifying the
 language option desired.

 User Action:  Specify a switch or file extension.

NOPRIMKEY

 There is no primary key for table <text>

 Explanation:  You ommitted the referenced column list in a
 referential    constraint for which the referenced table has not
 primary key.   If the referenced table has not primary key, you
 must specify   a column list which matches the columns in a
 unique constraint.

 User Action:  Add a referenced column list, or define a primary
 key for the    referenced table.

NOPROC

 SQL statements must follow a procedure declaration

 Explanation:  SQL statements must come after a procedure
 statement.  This statement was found before any procedure
 statement.

 User Action:  Put your SQL statements inside a procedure.

NORDBPRIV

 GRANT or REVOKE specified only unsupported privileges

 Explanation:  A GRANT or REVOKE statement specified only
 unsupported DB2 privileges.  It has no effect.

 User Action:  None.  VAX SQL ignores the statement.  However, to
 avoid this message, either remove the statement or add some
 supported privileges to it.

NORELFOU

 No relation found for map <text>

 Explanation:  The map name given has no table in the schema.

 User Action:  Use the correct map name.

NORELRES

 unable to import table <text>

 Explanation:  Could not import this table.  .  See the following
 message.

 User Action:  Correct the problem and retry the operation.

NORTPARM

 <text> is not declared in procedure <text>

 Explanation:  You used the parameter as a runtime parameter for
 a filename or pathname in a DECLARE SCHEMA statement.  Such
 parameters must be declared in every procedure in the module,
 and must be character datatypes.  You did not declare this
 paramter in this procedure.

 User Action:  Declare the parameter as a character variable in
 the procedure.

NOSCHALT

 Nothing altered in ALTER SCHEMA statement

 Explanation:  There was nothing altered in the ALTER SCHEMA
 query.

 User Action:  Remove the query or modify it to do something.

NOSEGSTRAREA

 segmented string storage area <text> is not defined

 Explanation:  You specified a storage area in the SEGMENTED
 STRING STORAGE AREA clause that does not exist.

 User Action:  Specify a storage area which is already defined in
 the CREATE SCHEMA statement.

NOSQLCA

 No INCLUDE SQLCA statement was specified

 Explanation:  Every precompiled SQL program must have an INCLUDE
 SQLCA statement in it.  This program did not have one.

 User Action:  Add an INCLUDE SQLCA statement.

NOSQLCODE

 Neither SQLCA nor SQLCODE were declared

 Explanation:  All precompiled SQL programs must include a
 definition for an SQL status variable.  This can be done by
 specifying an INCLUDE SQLCA statement or by defining an integer
 host variable name SQLCODE.  This program did neither.

 User Action:  Add either an SQLCODE variable or an INCLUDE SQLCA
 statement.

NOSTRDEF

 Host variable <text> is based on an undefined structure

 Explanation:  The FORTRAN RECORD host variable declaration uses
 a structure name which has not be declared.

 User Action:  Either change the name of the structure this host
 variable is based on, or define a structure with that name.

NOSTRNAM

 RECORD host variable <text> does not specify a structure name

 Explanation:  The FORTRAN RECORD host variable declaration does
 not specify the structure name which the record is based on.

 User Action:  Add the name of the structure this host variable
 is based on.

NOSUCHCUR

 Cursor <text> has not been declared

 Explanation:  You must declare a cursor before you refer to it
 in an OPEN, CLOSE, FETCH, UPDATE, or DELETE statement.

 User Action:  Declare the cursor, or use the name of a cursor
 which is already declared.

NOSUCHDATEFMT

 Format DATE <value> does not exist.

 Explanation:  User entered DATE n where the logical
    LIB$DATE_FORMAT_nnn does not exist.

 User Action:  Contact system manager to install the date
 formats.

NOSUCHLANG

 Language <text> does not exist.

 Explanation:  The user entered SET LANGUAGE xxx, but the logical
 name table LNM$LANGUAGE_xxx does not exist.

 User Action:  Contact the system manager to make sure everything
 has been properly set up; the language may not be supported.

NOSUCHTIMEFMT

 Format TIME <value> does not exist.

 Explanation:  User entered TIME n where the logical
    LIB$TIME_FORMAT_nnn does not exist.

 User Action:  Contact system manager to install the date
 formats.

NOTDB2

 "<text>" is a DB2 feature not supported by VAX SQL.

 Explanation:  This is a feature supported by DB2 that VAX SQL
 does not support.

 User Action:  Remove references to this feature.

NOTFOUND

 No rows were found for this statement

 Explanation:  No rows were found for an UPDATE or DELETE
 statement, or a query produced an empty table.

 User Action:  None, this is a warning message.

NOTGROFLD

 Column <text> cannot be referred to in the select list or HAVING
 clause because it is not in the GROUP BY clause

 Explanation:  In the select list and HAVING clauses of select
 expressions containing the GROUP BY clause, you can refer only
 to those columns named in the GROUP BY clause.

 User Action:  Either add the column named in the message to the
 GROUP BY clause, or delete from the select list or HAVING
 clause.

NOTHVDECL

 <text> is not a host variable

 Explanation:  The object referenced as a host variable was not a
 host variable.

 User Action:  Refer to a host variable.

NOTRGRES

 unable to IMPORT trigger <text>

 Explanation:  Could not import this trigger -- see the message
 that follows.

 User Action:  Correct the problem and retry the operation.

NOTUSEIND

 Cannot use indicator variables in WHERE or HAVING

 Explanation:  You cannot use indicator variables in WHERE
 clauses or HAVING clauses.

 User Action:  Use the NULL keyword to test if a value is null.

NOTYPES

 Domain reference in column <text> is illegal in a DECLARE TABLE
 statement

 Explanation:  You referred to a user defined domain in a DECLARE
 TABLE statement.  All domains in the DECLARE TABLE statement
 must be SQL predefined types.

 User Action:  Substitute the predefined equivalent of the user
 defined domain.

NOT_A_DB

 <text> is not the name of a DSRI-compliant database

 Explanation:  You supplied the name of a schema that does not
 exist under this data dictionary directory, or you supplied a
 name that is not a DSRI-compliant database.

 User Action:  Supply the name of a valid database.

NOT_CDD_DB

 Schema was not declared using PATHNAME.  Dictionary access is
 illegal.

 Explanation:  You tried to include a dictionary entity in the
 schema, but the schema itself is not using the dictionary.

 User Action:  Declare the schema using PATHNAME.

NOT_SAME_CONTEXT

 The <text> being defined must be in the same schema as the
 <text> it references

 Explanation:  When creating an item, the item was named as part
 of one schema, but it was being created from items of another
 schema.  For example, trying to create an index in one schema
 from a table in another schema generates this error.

 User Action:  Create the item naming only items from the same
 schema.

NOT_SCH_ID

 Authorization identifier <text> not permitted within definition
 of SCHEMA <text>

 Explanation:  You specified an authorization identifier of a
 schema that was other than the one for the schema being defined.

 User Action:  Create defintions only for a single schema in a
 CREATE SCHEMA statement.  Use the standalone CREATE statements
 for accessing other schemas.

NOVIERES

 unable to import view <text>

 Explanation:  Could not import this view -- see the message that
 follows.

 User Action:  Correct the problem and retry the operation.

NO_COMMAND

 An empty command string was passed to PREPARE.

 Explanation:  A null command string was passed to PREPARE.

 User Action:  Pass a string to PREPARE that is not empty.

NO_DCLTXN

 You cannot declare a transaction while a transaction is active.

 Explanation:  There is a currently transaction in progress.  You
 cannot declare a transaction while a transaction is in progress.

 User Action:  Commit or rollback the current transaction before
 issuing another DECLARE TRANSACTION statement.

NO_DECIMAL

 <text> is being converted from DECIMAL to <text>.

 Explanation:  DECIMAL is not a supported data type.  VAX SQL
 converts DECIMAL columns and types to a supported data type.

 User Action:  None.  This is an informational message only.

NO_DESCENDING

 DSRI does not support descending index segments

 Explanation:  You specified that a descending index segment;
 DSRI does not support descending index segments.

 User Action:  Remove the DESC clause from the index
 specification.

NO_DMLPLAN

 You can only use DECLARE statements in a context file.

 Explanation:  You can only include DECLARE statements in a
 context file.  These statements include DECLARE TRANSACTION,
 DECLARE SCHEMA, and DECLARE TABLE.

 User Action:  Remove everything but DECLARE statements from the
 context file.

NO_ENDCOM

 No comment terminator found

 Explanation:  A PL/I begin comment was found (/*) and no
 corresponding end comment (*/) was found before the end of the
 program.

 User Action:  Insert the comment terminator.

NO_ENDEXEC

 An EXEC SQL flag was found before the previous END-EXEC flag.

 Explanation:  The previous SQL statement was missing its
 END-EXEC flag.  Every COBOL SQL statement must be preceded by
 EXEC SQL and be terminated by END-EXEC.  A period may optionally
 follow the 'END-EXEC' flag.

 User Action:  Add an END-EXEC flag to the previous SQL
 statement.  Make sure that the END-EXEC flag has no embedded
 spaces, and that there is no COBOL terminator period before the
 END-EXEC flag.

NO_FILFND

 File <text> not found for input to the precompiler

 Explanation:  Attempted to open a nonexistent file.

 User Action:  Check the file specified.  Supply complete file
 specification.

NO_INCFND

 Could not find file <text> named in INCLUDE statement

 Explanation:  You attempted to include a nonexistent file.

 User Action:  Check the file specification in the INCLUDE
 statement.  Supply a complete file specification.  Note that the
 default file extension is .SQL.

NO_NUMERIC

 <text> is being converted from NUMERIC to <text>.

 Explanation:  NUMERIC is not a supported data type.  VAX SQL
 converts NUMERIC columns or types to a supported data type.

 User Action:  None.  This is an informational message only.

NO_PLNFND

 Context file <text> was not found for input to the precompiler

 Explanation:  Attempted to open a nonexistent context file.

 User Action:  Check the file specified.  Supply a complete file
 specification.

NO_SQLDA

 The SQLDA cannot be used in FORTRAN or COBOL

 Explanation:  PL/I is the only host language that supports the
 SQLDA.  This means you can only use the PREPARE...INTO and
 DESCRIBE statements in PL/I programs.  The only dynamic features
 supported by COBOL and FORTRAN are EXECUTE IMMEDIATE and
 EXECUTE, OPEN, and FETCH with host variable lists.

 User Action:  Remove references to the SQLDA from COBOL and
 FORTRAN programs.

NO_SUCH_FIELD

 Domain <text> does not exist in this schema

 Explanation:  You specified a domain that does not exist in the
 schema.

 User Action:  Check schema entity definitions for the valid
 schema type names.

NO_TXNOUT

 No transaction outstanding

 Explanation:  You attempted to terminate a transaction with a
 COMMIT or a ROLLBACK when no transaction was outstanding.  SQL
 does not start a transaction when you issue a DECLARE
 TRANSACTION, but waits until it encounters the first statement
 that requires a transaction.

 User Action:  Execute a statement that requires a transaction
 before issuing COMMIT or ROLLBACK.  All statements except
 DECLARE TRANSACTION, DECLARE SCHEMA, CREATE SCHEMA, and DROP
 SCHEMA require transactions.

NSEGBLR

 unable to recover BLR string

 Explanation:  Attempt to import a BLR segmented string with more
 than one segment.

 User Action:  Submit an SPR with a copy of the Rdb/VMS
 interchange file (.RBR) that caused the error.

NULLNOIND

 Tried to store null into host variable with no indicator
 variable

 Explanation:  Null values can only be stored in host variables
 which have indicator variables.

 User Action:  Add an indicator variable to the host variable
 reference or make sure that no null values can be returned to
 it.

NUMHVSNOT

 Number of host variables passed (<value>) does not match number
 of parameters (<value>)

 Explanation:  The number of host variables you passed in to an
 EXECUTE, OPEN, or FETCH statement does not match the number of
 parameter markers (question marks) in the PREPARE statement's
 command string.

 User Action:  Make sure the number of host variables matches the
 number of parameter markers in the PREPARE statement.  There are
 two ways to pass in host variables.  One, explicitly pass in a
 list of host variables in a USING list.  Or two, pass in an
 SQLDA in a USING DESCRIPTOR clause.  If you are using an SQLDA,
 you must specify in the SQLDA SQLN field the number of SQLVAR
 structures you have initialized to point to your variables.

NUMITESEL

 Number of items selected does not match number items in the INTO
 clause

 Explanation:  A SELECT statement must have as many values in the
 select list as there are in the INTO clause.

 User Action:  Enter the same number of columns in the select
 list and the INTO clause.  If you are using 'SELECT *', check
 the columns that are defined in the selected table.

NUM_TO_DATE

 Numeric data in column <text> cannot be converted to a date
 datatype

 Explanation:  Rdb will not allow numeric datatypes to be
 converted to date

 User Action:  Do not try it again.

ONEEPERM

 only one E character is permitted in an edit string

 Explanation:  An edit string contains more than one E character.
 Only one is allowed.

 User Action:  Redefine the edit string with only one E
 character.

ONETXNMOD

 Only one DECLARE TRANSACTION statement is allowed per module

 Explanation:  You can use only one DECLARE TRANSACTION statement
 in a preprocessed module.  It must occur before the first
 executable statement (SELECT, INSERT, UPDATE, CREATE, etc.).

 User Action:  Only use one DECLARE TRANSACTION statement in a
 module.

ONLFIRPRE

 Only the first file in the list will be precompiled

 Explanation:  You specified a list of files to be processed.
 This list will be passed along to the compiler with the first
 file replaced by the generated language file.  However, only the
 first file in the list will be precompiled.

 User Action:  If more than one of the files has SQL statements,
 they must be precompiled in separate command lines.  If you want
 only the first file precompiled, then no user action is
 neccessary.

ONLFIRVAR

 Only first variable in qualified variable expression

 Explanation:  COBOL allows only the first variable in a
 qualification to be an array.  The preprocessors do not
 recognize the arrays of arrays constructs in FORTRAN, COBOL or
 BASIC.

 User Action:  Rewrite the query and check the appropriate
 language reference manual.

ONLONEDB

 Only one schema can be referred to in this statement

 Explanation:  You cannot use objects from more than one schema
 in a SELECT, UPDATE, DELETE or CREATE statement.  You can,
 however, refer to tables from one schema in an INSERT statement
 and refer to tables in another schema in the SELECT which
 provides the values for that INSERT statement if the insert
 statement is not part of a trigger definition.

 User Action:  Use separate statements for multiple schema
 access.

ONLONETRN

 Only one transaction allowed at a time

 Explanation:  Only one transaction is allowed at a time.  Note
 that SQL starts a transaction, even if none was previously
 declared, on the first data manipulation statement.

 User Action:  Issue a COMMIT or ROLLBACK statement to terminate
 the transaction, then declare another.

ONLYONEPSECT

 Only one PSECT statement per module is supported

 Explanation:  The PSECT directive may only be used once per
 module.

 User Action:  Decide which PSECT statement is really desired and
 delete all others.

OPENERR

 unable to open <text> as the interchange file

 Explanation:  Could not access the Rdb/VMS interchange file
 (.RBR).

 User Action:  Correct the problem indicated by subsequent
 messages and retry the operation.

OPRSTK_OVRFLO

 Operator stack overflow

 Explanation:  The internal limit of the parsing operator stack
 was exceeded.

 User Action:  Submit an SPR with the query that caused the
 error.

PARAMNOTSTR

 Parameter <text> in procedure <text> must be a character
 parameter

 Explanation:  You used the parameter as a runtime parameter for
 a filename or pathname in a DECLARE SCHEMA statement.  Such
 parameters must be declared in every procedure in the module,
 and must be character datatypes.  The parameter in this
 procedure is not a character datatype

 User Action:  Declare the parameter as a character variable in
 the procedure.

PARAMQUAL

 Parameters must not be qualified

 Explanation:  A reference to a parameter included qualifiers.
 You cannot qualify parameters.

 User Action:  Define the parameter in the procedure, or use a
 parameter name which is defined in the procedure.

PARBADCLA

 Parameter <text> passed by invalid descriptor class

 Explanation:  The parameter was passed to a module language
 procedure by descriptor when parameter checking was enabled and
 the class of the descriptor was not a supported descriptor
 class.

 User Action:  Correct the argument in the host language program

PARBADDAT

 Parameter <text> has invalid datatype

 Explanation:  The parameter was passed to a module language
 procedure with a different datatype than it was declared in the
 procedure.

 User Action:  Make the parameter agree in the module and the
 host language.

PARBADLEN

 Parameter <text> has invalid length

 Explanation:  The parameter was passed to a module language
 procedure with a different length than it was declared in the
 procedure.

 User Action:  Make the parameter agree in the module and the
 host language.

PARBADSCA

 Parameter <text> has invalid scale

 Explanation:  The parameter was passed to a module language
 procedure with a different scale than it was declared in the
 procedure.

 User Action:  Make the parameter agree in the module and the
 host language.

PARBINSCA

 Parameter <text> has a binary scale factor

 Explanation:  The parameter was passed to a module language
 procedure with a binary scale factor.  VAX SQL supports only
 decimal scale factors.

 User Action:  Either do not use a scale factor, or use a
 datatype with which your language uses decimal scale factors.
 For example, PL/I uses binary scale factors with fixed binary
 data and decimal scale factors with fixed decimal data.  If you
 want to use scale factors, use fixed decimal.  Be sure to change
 the module to agree with the new datatype.

PARSE_STACK_OVERFLOW

 Parse stack overflow

 Explanation:  The internal limit of the parsing stack were
 exceeded.

 User Action:  Submit an SPR with the query that caused the
 error.

PASRECUNS

 Host variable <text> is based on a record type that is
 unsupported

 Explanation:  The host variable you referred to is based on a
 record type which is unsupported.

 User Action:  Use a different type defintion.

PASVARUNS

 Host variable <text> is based on a record type that uses
 variants

 Explanation:  The host variable you referred to is based on a
 record type which uses Pascal variants.  VAX SQL does not
 support types which include variants.

 User Action:  Use a different type defintion.

PATH_NAM_REQ

 PATHNAME clause necessary when the dictionary is required

 Explanation:  When you create a schema using the DICTIONARY IS
 REQUIRED       clause, then you must also specify the PATHNAME
 clause.

 User Action:  Change the CREATE SCHEMA statement to either add
 the    the PATHNAME clause or to remove the    DICTIONARY IS
 REQUIRED clause.

PHYBACDAT

 it was physically exported on <text>

 Explanation:  Information about the Rdb/VMS interchange file
 (.RBR).

 User Action:  None.

PKNOTNULL

 Column <text> is used in a primary or unique key but permits
 NULLs

 Explanation:  You specified a column in a primary or unique key
 definition     which permits NULL values.  The current ANSI and
 ISO SQL        standards require that only fields for which not
 null is        specified may be included in a primary or unique
 key.

 User Action:  If it is important to have only standard syntax in
 your   program, you should either remove the column from the
   primary or unique key, or add the NOT NULL attribute to
      the column.

PREFORSTR

 The host variable in the PREPARE FROM clause must be a string.

 Explanation:  A host variable in the FROM clause of a PREPARE
 statement must have a string data type.

 User Action:  In COBOL declare the variable to be PIC X(n).  In
 PL/I declare the variable to be CHAR(n).  In FORTRAN, declare
 the variable to be CHARACTER XYZ*n.

PREMATURE_EOF

 Statement is syntactically incomplete

 Explanation:  You entered a syntactically incomplete statement.

 User Action:  Complete the statement before typing "RETURN".

PRESTAOPE

 Cannot prepare statement name used by an open cursor

 Explanation:  You declared a cursor based on a prepared
 statement name and opened the cursor.  While that cursor was
 still open, you tried to prepare the same statement name again.

 User Action:  Close the cursor or end the transaction before
 using a PREPARE statement with the same statement name again.

PRIKEYEXI

 There is already a primary key for table <text>

 Explanation:  You specified a primary key definition for a table
 which  already had one.  There can only be one primary key for a
 table.

 User Action:  Remove the primary key definition from the
 statement, or delete   the existing primary key before executing
 the statement.

PRINT_SSID

 Segmented string id for <text> will be displayed

 Explanation:  One of the columns specified in the select list of
 a SELECT statement is a segmented string.  SQL does not support
 the segmented string data type, but displays the segmented
 string identifier for interactive SELECT statements.  The
 segmented string identifier is an internal value which will
 probably not be meaningful.

 User Action:  Ignore the values displayed for the segmented
 string column.

PROCNOCA

 Procedure <text> has neither an SQLCA nor SQLCODE parameter

 Explanation:  A module language procedure must have either an
 SQLCA or an SQLCODE parameter declared.  This procedure had
 neither.

 User Action:  Add either an SQLCODE or SQLCA parameter.

PRPSELINTO

 Preprocessed SELECT statements must include an INTO clause

 Explanation:  A preprocessed SELECT statement needs a place to
 put the data it retrieves.  An INTO clause is required to
 specify where to put the data.

 User Action:  Add an INTO clause to the SELECT statement.

PTR_VAR

 Host variable <text> is a pointer variable which is illegal in
 SQL statements.

 Explanation:  The named variable is defined as a C pointer
 variable.  These variables are currently not supported by the C
 precompiler.

 User Action:  Use a different variable.

PUTOPESEG

 Attempt to put to an opened segmented string

 Explanation:  You attempted to do a SEGSTR.PUT using a handle
 returned by a SEGSTR.OPEN statement.  You can only do
 SEGSTR.GETs using the handle returned by open.

 User Action:  Specify the correct handle

QUAINVVAL

 An invalid value <text> was specified for <text>

 Explanation:  You specified an invalid value for a command line
 qualifier

 User Action:  Correct the command line syntax error.

QUANOVAL

 The <text> qualifier does not take a value

 Explanation:  You specified a value for a command line qualifier
 which cannot have a value.

 User Action:  Correct the command line syntax error.

RDBVMSONL

 Operation supported for Rdb/VMS databases only

 Explanation:  You issued a GRANT or REVOKE statement on a
 non-Rdb/VMS database.  VAX SQL supports GRANT and REVOKE for
 Rdb/VMS databases only.

 User Action:  Do not issue any GRANT or REVOKE statements with
 this database.

REANOWRT

 A READ_ONLY transaction can not specify write locks.

 Explanation:  The transaction was specified as READ_ONLY but a
 table in the RESERVING clause was locked for write access.  This
 is a conflict of access modes.

 User Action:  Declare the transaction READ_WRITE or use a read
 lock.  Note that the default is always READ_WRITE.

REAONLATT

 Read Only attribute was specified with other attributes

 Explanation:  The attributes in addition to READ ONLY were
 specified in   the ALTER STORAGE AREA clause.  If you change a
 storage area   to read only, that is all you can do..

 User Action:   Execute in separate ALTER SCHEMA commands.

RECEXCMAX

 size of edit string exceed internal data structure limits

 Explanation:  The length of an edit string exceeds the size of
 the internal data structures that used to represent it.

 User Action:  Temporarily reduce the size of the edit string and
 submit an SPR including a description of the table and domains
 that produce this error.

REFKEYCOL

 Referencing column <text> and corresponding referenced column
 <text> do not match

 Explanation:  A referencing column and its corresponding
 referenced column must have the same datatype, size and scale.
 These 2 columns do not.

 User Action:  Specify a referential constraint where the columns
 all match.

REFKEYNUM

 The referencing and referenced columns have different lengths

 Explanation:  The referencing column list and the referenced
 column list (explicit or implicit) must have the same number of
 columns.  They do not for this referential constraint.

 User Action:  Change the lists to match.

RELAMBIG

 Table name <text> was not qualified and is in multiple schemas

 Explanation:  You must qualify a table name with an
 authorization identifier when accessing more than one schema
 containing that table name.

 User Action:  Make sure the DECLARE SCHEMA statements for the
 schema include authorization identifiers and retype the query
 using the appropriate authorization identifier.

RELNOTDEF

 Table <text> is not defined in schema

 Explanation:  The specified table does not exist in the current
 schema.

 User Action:  Declare the correct schema.  Spell the table name
 correctly.  You may have specified a name other than a table
 name.

REL_EXISTS

 Table <text> already exists in this schema

 Explanation:  You attempted to create a table with the name of
 an existing table

 User Action:  Choose a different name.

REORGONLALTSM

 Reorganize is only legal with ALTER STORAGE MAP

 Explanation:  The user specified the REORGANIZE clause in a
 statement      other than an ALTER STORAGE MAP.

 User Action:  Remove the reorganize clause.

RESABORT

 terminating the IMPORT operation

 Explanation:  The IMPORT operation has been aborted; see the
 messages preceding this one.

 User Action:  None.

RESERVED_WORD

 <text> is a keyword.  It cannot be used as a name

 Explanation:  You entered a keyword where a name was expected.

 User Action:  Specify a unique name instead of the keyword.

SEGAREERR

 Segmented string area <text> referred to but not defined

 Explanation:  The CREATE SCHEMA statement indicated that
 segmented strings      must be stored in a specific storage
 area, but that storage         area was never created.

 User Action:  Change the CREATE SCHEMA statement to include a
 CREATE STORAGE         AREA statement with the name referred to
 by the         SEGMENTED STRING clause.

SEGSTREXP

 Cannot use a segmented string in an expression

 Explanation:  You attempted to use a segmented string column in
 an expression.  Segmented strings may be used only in
 expressions using the NULL operator.

 User Action:  Remove the operations on the segmented string from
 the DML query.

SELMORVAL

 The result of a singelton select returned more than 1 value

 Explanation:  A singleton select statement (SELECT...INTO) may
 only return 1 row of values.  The result table for this
 singleton select contains more than one row.

 User Action:  Either embed the SELECT statement (without the
 INTO clause) in a DECLARE CURSOR statement and process it with
 OPEN and FETCH statements, or modify the SELECT statement so it
 will return only one row.

SEVERRDET

 A severe error was detected

 Explanation:  This is the exit status for a preprocessor when a
 severe error is detected.

 User Action:  Fix the error.

SHDESCEND

 descending

 Explanation:  Used in the SHOW INDEXES statement --

SHOTABMAPDR

 Storage Map for table <text>.<text>:

 Explanation:  Used in SHOW TABLE

SMA_DAT_TYP

 Altering column <text> to a smaller datatype may cause data loss

 Explanation:  Altering a column to a smaller datatype might
 cause data     already stored in that column to appear lost.

 User Action:  None.  This is a warning message only.

SPACREQ

 A space is required before file specification

 Explanation:  A space is required to parse the begining of the
 file specification.

 User Action:  Run the preprocessor again and include a space
 before the file specification.

SPANOTVAL

 Space management options not valid on areas with uniform page
 format

 Explanation:  Space management options of thresholds, interval
 or both        were specified for an area with a uniform page
 formats.

 User Action:  Remove the space management option(s) from the
 storage area   with uniform page format, or change the storage
 area with      the specified space managment option(s) to have
 mixed page     format.

SQLDANOT

 SQLDA not large enough (<value>) to handle number of parameters
 (<value>)

 Explanation:  The SQLDA passed to PREPARE or DESCRIBE is not
 large enough to handle all of the parameters in the associated
 PREPARE command string.

 User Action:  Allocate an SQLDA to be large enough to have one
 SQLVAR for each input or output parameter ('?') in the PREPARE
 command string.  Then set SQLN to indicate the number of SQLVARs
 in the SQLDA.

SQLDATA

 An SQLDATA field in the SQLDA was not initialized

 Explanation:  You passed in an SQLDA with a SQLDATA value of
 zero in one of the SQLVAR blocks.

 User Action:  You must enter nonzero values in every SQLDATA
 field in the prepared command string that SQLD indicates is
 necessary.

SQLTYPE

 An invalid SQLTYPE value of <value> was found in the SQLDA

 Explanation:  You passed in an SQLDA with a illegal SQLTYPE
 value.

 User Action:  You must enter a valid SQLTYPE value in every
 SQLTYPE field in the prepared command string that SQLD indicates
 is necessary.

STANOTDEF

 The '<text>' statement has not been defined

 Explanation:  You attempted to use a statement name in an
 EXECUTE or a DESCRIBE statement that had not been used in a
 PREPARE statement.

 User Action:  Prepare a statement name before using it in an
 EXECUTE or a DESCRIBE statement.

STANOTSEL

 Cursor can only be used with prepared SELECT statements

 Explanation:  You attempted to declare a cursor based on a
 prepared statement that was not a SELECT statement.  Cursors can
 be based only on SELECT statements.

 User Action:  Use EXECUTE to execute this statement.

STAREQCOL

 The standard requires a column in this context

 Explanation:  The ANSI and ISO SQL standards require that you
 specify        a column which is not in an expression in this
 context.

 User Action:  If it is important to have only standard features
 in your        program, you should change your querry to use a
 column here

STARNOTALL

 Invalid use of asterisk - expected column name

 Explanation:  You attempted to use the column wildcard (*) where
 SQL requires an explicit column name.

 User Action:  Supply the names of the columns to be referenced.

STATWOCUR

 Cannot declare a second cursor based on statement <text>

 Explanation:  A prepared statement can only have one cursor
 based on it.  You tried to declare a second cursor based on the
 same prepared statement name used in a previous DECLARE CURSOR
 statement.

 User Action:  Remove one of the cursor definitions from your
 program or base the second cursor on a different statement name.

STOCOLERR

 Not enough columns were specified in the USING clause

 Explanation:  There were more literals specifed in the LIMIT
 clause of      the storage map than there were columns in the
 USING clause.

 User Action:  Either specify more columns in the USING clause,
 or reduce the  number of literals in the LIMITS clause.

STOCOLUKN

 Column specified in STORE clause, <text>, is unknown to table
 <text>

 Explanation:  A column that did not exist in the table was used
 in the         CREATE STORAGE MAP statement.

 User Action:  Specify a valid column name.

STOTABUKN

 Table specifed in store clause, <text>, is unknown to this
 schema.

 Explanation:  The table named in the CREATE STORAGE MAP
 statement does not     exist in the schema.

 User Action:  Specify a valid table name.

STRARRAY

 Host variable <text> is either a structure array or in a
 structure array

 Explanation:  The SQL precompilers do not support references to
 fields in a structure array (a host structure defined as an
 array).

 User Action:  Assign the value in the structure array to a field
 which is not in a structure array before using it in an SQL
 statement.

STRINXPR

 Host structure <text> used in a value expression

 Explanation:  SQL statements can only refer to a host structure
 in contexts where the host structure can be expanded to a list
 of values.  A value expression requires a single value, so host
 structures cannot be used there.

 User Action:  Replace the host structure with an elementary
 item.

STRLITEXP

 A string literal was expected

 Explanation:  A string literal was expected but something else
 was found.

 User Action:  Correct the syntax error.

STRLITMISQUO

 String literal missing closing quote

 Explanation:  The string in a user assignment statement is
 missing a closing quote.

 User Action:  Insert one or more quotes as appropriate.

STRMORELE

 The <text> structure has more elements than the <text> indicator
 vector

 Explanation:  The specified structure has more elements than the
 indicator vector it is associated with.

 User Action:  Make the indicator vector larger.

STRTOOBIG

 String literal is too big

 Explanation:  You entered a string literal with a length greater
 than 1024 characters.  The length of a string literal must be
 less than or equal to 1024 characters.  A likely cause of this
 error is an unmatched quote mark.

 User Action:  Put missing quote marker, or use a string literal
 with no more than 1024 characters.

STRTOOLON

 String expression must not be longer than <value>

 Explanation:  The string expression must be shorter than the
 specified      length.  For example a database filespec must be
 less than      255 characters.,

 User Action:  Specify a shorter string expression

STRXPREXP

 A string expression was expected

 Explanation:  A string literal, a character host variable, or
 USER was expected but something else was found.  (Note that USER
 is not permitted in EXECUTE IMMEDIATE, and specifying it will
 also generate this message.)

 User Action:  Correct the syntax error.

SUBNOGB

 Subqueries in basic predicates cannot use GROUP BY

 Explanation:  A subquery used in a basic predicate, such as
 WHERE CITY = (SELECT ...), cannot contain the GROUP BY clause.
 The ANSI standard does not support this.

 User Action:  If it is important to have only standard SQL
 statements in your program, remove the GROUP BY clause or change
 the predicate to include ANY or ALL.

SUBTOOVAL

 Column select expression specifies too many columns

 Explanation:  A column select expression may only fetch one
 value unless it is in an EXISTS predicate.  This means any
 column select expression that uses the column wildcard (*) must
 have only one-column tables in its FROM clause.

 User Action:  If you specified more than one column explicitly,
 remove all but one.  If you used a wildcard, explicitly name a
 single column instead.

SYM_EXP

 One of the following symbols was expected:

 Explanation:  You typed an unexpected keyword.

 User Action:  Type a correct keyword.

SYNTAX_ERR

 Syntax error

 Explanation:  A syntax error was detected in a your SQL
 statement.

 User Action:  Correct the syntax error and retry the statement.

SYSPAGFOR

 Page format for system relations cannot be MIXED

 Explanation:  The system relations for Rdb/VMS must be placed in
 an area        that contains the uniform page format.

 User Action:   Either create a separate storage area for
 RDB$SYSTEM or change   the default page format to uniform.

SYSPAGUNI

 Page format for system relations being changed to UNIFORM

 Explanation:  The storage area that contain the system relations
 must   have UNIFORM page formats.  Either through the use of the
 defaults, or by directly specifing PAGE FORMAT IS MIXED,
       SQL has been told to use MIXED page format for the area
  containing the system relations.  SQL is overriding that
      to UNIFORM pages.

 User Action:  Nothing.  This is an informational message.  The
 user might     want to change the command if it originated in a
 command        file.  This may avoid confusion later.

S_STOAREA_READONLY

 Access is:  Read only

 Explanation:  Used in SHOW STORAGE AREA

S_STOAREA_READWRITE

 Access is:  Read write

 Explanation:  Used in SHOW STORAGE AREA

TBLCOLAFT

 You mixed COLUMN and TABLE privileges and used a POSITION or
 AFTER clause

 Explanation:  You specified both COLUMN and TABLE privileges in
 a GRANT or REVOKE statement that had a POSITION or AFTER clause
 for one of the TO clauses.  Unless the ACLs are identical on
 both the column and the table, this could have misleading
 results.

 User Action:  If the ACLs on the column and table are not
 identical, split the table and column privileges into 2 separate
 statements.

TBLNOTCUR

 Table <text> is not included in cursor <text>

 Explanation:  An UPDATE or DELETE statement that uses the
 CURRENT OF clause must name the same table specified in the
 cursor.

 User Action:  Either change the UPDATE or DELETE statement to
 use the table specified in the cursor, or use a cursor declared
 for the table you specified.

THRIGNSYS

 Threshold options ignored for system relation area

 Explanation:  The storage area that contain the system relations
 must   have UNIFORM page formats.  Either through the use of the
 defaults, or by directly specifing THRESHOLD options,  SQL has
 been told to apply threshold options for the area
      containing the system relations.  SQL is ignoring those
   options.

 User Action:  Nothing.  This is an informational message.  The
 user might     want to change the command if it originated in a
 command        file.  This may avoid confusion later.

THRNOTSYS

 Theshold option not valid for system relation area

 Explanation:  The storage area for RDB$SYSTEM was defined to
 have threshold         options.  This is not allowed for
 RDB$SYSTEM.

 User Action:  Remove the threshold option from the command and
 try again.

TOKINSBEF

 <text> inserted before error symbol

 Explanation:  When parsing an SQL statement, the parser
 encountered an error.  The message for that error appeared prior
 to this message.  In an attempt to recover from that error, SQL
 inserted the specified token before the token that generated the
 error, and generated this message to help you understand any
 additional messages that follow.

 User Action:  None.  This is an informational message only.

TOKTOOBIG

 Symbol name is too big

 Explanation:  You entered a symbol (token) name with a length
 greater than 32.  The length of a symbol name must be less than
 or equal to 32 characters.

 User Action:  Use a symbol with no more than 32 characters.

TOOBIGBLR

 request BLR would be too large to execute

 Explanation:  The user's request is too large to be compiled.

 User Action:  The DML statement must be broken up into smaller
 parts.

TRAACT

 A schema cannot be declared while a transaction is active

 Explanation:  You issued an DECLARE SCHEMA statement while a
 transaction was still in progress.

 User Action:  You must either COMMIT or ROLLBACK the current
 transaction or wait until the current transaction is terminated
 before declaring another schema.

TRAACT_1

 A schema cannot be created or altered while a transaction is
 active

 Explanation:  You issued a CREATE SCHEMA or an ALTER SCHEMA
 statement while a transaction was still in progress.

 User Action:  You must either COMMIT or ROLLBACK the current
 transaction or wait until the current transaction is terminated
 before creating another schema or altering an exsisting one.

TRAACT_2

 ROLLBACK or COMMIT the transaction

 Explanation:  You are attempting an operation that cannot be
 executed while the current transaction is still in progress.

 User Action:  You must either COMMIT or ROLLBACK the current
 transaction or wait until the current transaction is terminated
 before attempting the new schema activity.

TRAACT_3

 A schema cannot be dropped while a transaction is active

 Explanation:  You issued a DROP SCHEMA statement while a data
 manipulation transaction was still in progress.

 User Action:  COMMIT or ROLLBACK the transaction, start a new
 transaction, and reissue the DROP SCHEMA statement.

TRAHDLINV

 Transaction handle datatype invalid, must be longword

 Explanation:  You specified a transaction handle that was not a
 longword.

 User Action:  You must use !VAL and longword variable.

TRAMODSPC

 Only one transaction mode may be specified for a transaction

 Explanation:  You specified both the READ_WRITE and READ_ONLY
 transaction modes in a DECLARE TRANSACTION statement.

 User Action:  Specify either transaction mode, not both, for a
 single schema.  You can specify different transaction modes for
 different schemas in a single DECLARE TRANSACTION statement,
 however.

TREE_OVRFLO

 Tree storage overflow

 Explanation:  The internal limit of the AST tree nodes was
 exceeded.

 User Action:  Submit an SPR with the query that caused the
 error.

TXNNOTLONG

 Transaction handle is not a longword.

 Explanation:  Transaction handles must be defined using the VAX
 longword data type.

 User Action:  Use a longword to declare the transaction handle:
 In COBOL, use PICTURE S9(9) COMP.  In PL/I, use FIXED
 BINARY(31).  In FORTRAN, use INTEGER*4.

TXN_HNDL_IGNORED

 Transaction handle parameter ignored

 Explanation:  Transaction handles currently are not supported.

 User Action:  None; this is an informational message.

UKN_ALT_OPT

 Unknown ALTER SCHEMA option

 Explanation:  The ALTER SCHEMA statement contains an option that
 is not         understood.

 User Action:  Reenter the statement with the syntax supported by
 this   version of VAX SQL.

UNBDECFIL

 Unable to create declarations file <text>

 Explanation:  SQL attempted to open a DECLARATIONS file but
 could not.

 User Action:  Include a valid directory specification and valid
 declarations name.

UNBTMPFIL

 Unable to open a temporary file called <text>

 Explanation:  SQL attempted to open a temporary file.  It was
 either in the default directory or the directory specified with
 the /OBJ compile switch.

 User Action:  Include a valid directory specification with
 protection level that allows temporary files to created in it.

UNDEFVAR

 Variable <text> is not defined

 Explanation:  You referenced a host variable which is not
 defined.

 User Action:  Either define the variable, or specify the name of
 a variable which is already defined.

UNDPARAM

 Parameter <text> is not declared in procedure <text>

 Explanation:  This error is generated in two situations.  In the
 first, a procedure referred to a parameter which was not
 declared in the procedure.  In the second, you used a column in
 a context where it could be a parameter reference and an
 indicator variable was specified (or a comma omitted).

 User Action:  Define the parameter in the procedure, or use a
 parameter name which is defined in the procedure.

UNISELLIS

 The standard requires the select lists of the selects for UNION
 to have the same number of columns

 Explanation:  The select lists of the 2 select expressions in
 this UNION     have a different number of elements.  The ANSI
 and ISO SQL    standards require that they have the same number
 of elements.

 User Action:  If it is important to have only standard features
 in your        program, you should change your selects to have
 the same number        of items in the select list.

UNKTYPE

 <text> is based on an unknown type

 Explanation:  You referred to a host variable which was based on
 a host language the SQL precompiler does not support.

 User Action:  Base the host variable on a host language the SQL
 precompiler supports.

UNSDATATYPE

 Host variable <text> is an unsupported datatype

 Explanation:  The host variable declaration uses a COMPLEX or
 REAL*16 FORTRAN data type.  These data types are not supported.

 User Action:  Either change the declaration so that only
 supported data types are used, or move the data to another data
 item which only uses supported data types.

UNSDB2PRIV

 Unsupported DB2 privilege ignored

 Explanation:  A GRANT or REVOKE statement specified a DB2
 privilege which VAX SQL does not support.

 User Action:  None.  VAX SQL ignores the unsupported privileges.

UNSDSCCLA

 Unsupported descriptor class <value>

 Explanation:  The class of the descriptor in an input parameter
 is not supported by VAX SQL.

 User Action:  Use class S, D, DS, or VS.

UNSDTPCVT

 Unsupported data type conversion

 Explanation:  A dynamic SQL program tried to get SQL to perform
 a data type conversion which it does not support.  For example,
 a date field was fetched into a numeric field.  The VAX SQL
 dynamic interface does not support conversions from date to
 numeric.

 User Action:  Change the data type used to pass data to or from
 the dynamic interface to a data type which can be converted to
 the data type of the data in the database.

UNSIGNED_VAR

 Host variable <text> is an unsigned variable which is illegal is
 SQL statements.

 Explanation:  The named variable is defined as an C unsigned
 variable.  Unsigned variables are illegal in SQL statments.

 User Action:  Use a signed version of this variable in the SQL
 statement.

UNSPLIATT

 Host variable <text> uses an unsupported PLI attribute

 Explanation:  The host variable declaration uses a PLI attribute
 which is not supported.

 User Action:  Either change the declaration so that only
 supported attributes are used, or move the data to another data
 item which only uses supported attributes.

UNSSTRXPR

 Unsupported string expression

 Explanation:  You attempted an operation on a string that is not
 supported.  For example:  string = string + string;

 User Action:  Check the documentation for valid string
 expressions.  If you are using the preprocessors, you might be
 able to work around the limitation by using a temporary
 variable.

UNSSUPDAT

 Unsupported datatype requested

 Explanation:  You requested input or output of an unsupported
 data type from the dynamic interface.

 User Action:  You should review the data types of the variables
 in the dynamic statement and change the offending data type to a
 supported data type.

UNSUPOP

 Operation supported for read-write databases only

 Explanation:  You attempted to perform data definition or
 updates on a VIDA database.  VIDA databases are read-only.

 User Action:  Do not issue any CREATE, INSERT, UPDATE, or DELETE
 statements with a VIDA database.

UNTSTR

 Unterminated string found

 Explanation:  The matching quote (" or ') for a string was not
 found.

 User Action:  Reenter statement with matching quote character.

UPDCOLPRIV

 UPDATE(column-name) privilege is not supported

 Explanation:  UPDATE(column-name) is a DB2 privilege not
 supported by VAX SQL.  UPDATE privilege will be granted on the
 entire table.

 User Action:  None.

UPDREACUR

 Cursor <text> is read-only

 Explanation:  A cursor is read-only if it includes a DISTINCT
 phrase, a function, a GROUP BY, HAVING, or ORDER BY clause, or
 more than one table in its FROM clause.  Read-only cursors
 cannot include FOR UPDATE clauses and cannot be used in UPDATE
 or DELETE statements.

 User Action:  Either change whatever made the cursor read-only,
 or do not attempt to update the cursor.

USERINVIEW

 USER literals are not permitted in DDL statements

 Explanation:  VAX SQL cannot store a USER literal in a ddl
 object such as a view or a constraint.

 User Action:  You must either explicitly specify the user name
 as string literal in the select list of the view definition, or
 specify USER in a query outside of the view definition.

USRDEFTYP

 Host variable <text> is of an unknown user defined type

 Explanation:  The named variable is of a user defined type that
 wasn't defined within the pre-compilation unit.  User defined
 types must be defined in the same pre-compilation unit for them
 to be legal.

 User Action:  Use a different variable or include the type
 definition in the pre-compilation unit.

VECNOTIND

 Host variable <text> is a vector but is not used as an indicator
 structure

 Explanation:  The host variable is defined as a vector
 (one-dimensional array).  SQL only allows references to vectors
 if they are used as indicator variables for host structures
 (such indicator variables are also called indicator structures
 or indicator vectors).

 User Action:  Either change the host variable declaration so it
 is not an array, or move the data from the array to a variable
 that is not an array.

VEWNOTDEF

 View <text> is not defined in schema

 Explanation:  The specified view does not exist in the current
 schema.

 User Action:  Declare the proper schema.  Spell the view name
 correctly.  You may have specified an expression where a view
 name was expected.

WAIMODSPC

 Only one wait mode may be specified for a transaction

 Explanation:  You specified both wait modes in a DECLARE
 TRANSACTION statement.

 User Action:  Specify either WAIT or NOWAIT, not both, in a
 DECLARE TRANSACTION statement.

WARDET

 A warning was detected

 Explanation:  This is the exit status for a preprocessor when an
 warning was detected.

 User Action:  Correct the error in the host language program and
 resubmit the job to the preprocessor.

WHYTWICE

 Column <text> is specified more than once in the column list of
 a constraint.

 Explanation:  You specified the same column more than once in
 the column list of a UNIQUE, PRIMARY KEY or FOREIGN KEY
 constraint.

 User Action:  Specify each column only once.

WISH_LIST

 Feature not yet implemented

 Explanation:  The action you requested requires a feature that
 is not implemented in the current version of this product.

 User Action:  Try to work around the unimplemented feature.

WRICIRREF

 A subquery in an INSERT, UPDATE or DELETE statement referenced
 the subject table

 Explanation:  You tried to use the same table in an INSERT,
 UPDATE or DELETE statement both as the target and in a subquery.
 The current ANSI and ISO SQL standards do not permit this.

 User Action:  If it is important to use only standard features
 in your program, you should remove the subquery which references
 the subject table.

ZABORT

 User entered Control-Z to abort statement

 Explanation:  You typed a Control-Z to abort the current
 statement.

 User Action:  None.

Execute(@)

 @file-spec

 The 'at' sign (@) means "execute" in interactive SQL, just as in DCL.
 When you type @ and the name of an indirect command file, interactive
 SQL executes the statements in the file as if you had typed them one
 at a time at the interactive SQL prompt.  The default file type for
 an indirect command file is .SQL.  You can use the SET VERIFY
 statement to have the commands in the file displayed on the screen as
 they execute.

 The file-spec argument to the @ statement is the name of an indirect
 command file.  You can use either a full VMS file specification, a
 file name, or a logical name.  If you use a file name, interactive
 SQL looks in the current default VMS directory for a file by that
 name.  The file must contain valid interactive SQL statements.

Additional information available:

Examples

Examples

 You can use an indirect command file to execute a frequently used
 query:

 $ TY EMPADDR.SQL
 !
 ! This command file generates information for a mailing list.
 !
 SET OUTPUT 'DISK2:[DEPT32]MAILLIST.DOC'
 SELECT  FIRST_NAME, MIDDLE_INITIAL, LAST_NAME,
         ADDRESS_DATA_1, ADDRESS_DATA_2, CITY, STATE, POSTAL_CODE
 FROM EMPLOYEES
 $ SQL
 SQL> @EMPADDR

Functions

 The keywords COUNT, AVG, MAX, MIN, and SUM specify SQL
 functions.  Functions calculate values based on a value
 expression for every row in a result table.  Functions are
 sometimes called "statistical expressions" or "aggregate
 expressions" because they calculate a single value for a
 collection of rows in a result table.  Functions calculate a
 single value:

    COUNT       Number of rows in a result table

    SUM         Sum of the values in a column

    AVG         Average of the values in a column

    MAX         Largest value in a column

    MIN         Smallest value in a column

Additional information available:

More Information

More Information

 The following notes apply in general to functions:

  o  Rows with null values are not included when SQL evaluates
     functions.  If you specify DISTINCT, redundant values in
     rows are also not included.

  o  SUM calculates the total of the values specified by the
     value expression in its argument.  If there are no rows in
     the result table to which SUM is applied, it returns null.

  o  If a function has as its argument a value expression
     containing a column name that is an outer reference, the
     value expression cannot include an arithmetic operator.
     (The only cases where an outer reference makes sense as the
     argument to a function is in the subquery of a HAVING
     clause, or in a subquery in a select list.)


 Select More_Information to continue.

Additional information available:

More Information

More Information

  o  You cannot nest functions.  This means that a value
     expression used as an argument to a function cannot include
     a function.

  o  The keyword ALL in SUM, AVG, MAX, and MIN has no effect.
     For instance, specifying MAX (ALL EMPLOYEE_ID) is the same
     as saying MAX (EMPLOYEE_ID).

GRANT ANSI style

 GRANT  ───────────>───────────┐
                               │
 ┌───────────────<─────────────┘
 └─┬─> schema-privs-ansi ─> 
O

N

S

C

H

E

M

A
typebox (A)typebox (U)typebox (T)typebox (H)typebox (O)typebox (R)typebox (I)typebox (Z)typebox (A)typebox (T)typebox (I)typebox (O)typebox (N) ─┬─> auth-id ─┬─┬─┐ │ └───── , <───┘ │ │ ├─> table-privs-ansi ─> 
O

N
┬─────>─────┬┬─> table-name ──┬──────┤ │ │ └─> 
T

A

B

L

E
──┘└─> view-name ───┘ │ │ └─> column-privs-ansi ─> 
O

N

C

O

L

U

M

N
──┬─> column-name ──┬─────────┘ │ └─────── , <──────┘ │ ┌────────────────────── ───────<──────────────────────────────────┘ └─> 
T

O
─┬─┬─> identifier-ansi-style ─┬──┬────┐ │ └─> 
P

U

B

L

I

C
────────────────┘ │ │ └───────────── , <──────────────┘ │ ┌────────────────────<───────────────────┘ └──┬──────────>───────────┬─> typebox (;) └─> 
W

I

T

H

G

R

A

N

T

O

P

T

I

O

N
─┘

Additional information available:

WITH_GRANT_OPTION

More Informationcolumn privstable privsschema privsidentifier ansi style

More Information

 The ANSI style GRANT statement creates or adds privileges to an
 entry to the Rdb/VMS access privilege set for a database, table,
 column, or view.  Each entry in an access privilege set consists
 of an identifier and a list of privileges assigned to the
 identifier:

  o  Each identifier specifies a user or PUBLIC.

  o  The set of privileges specifies what operations that user or
     user group can perform on the database, table, or column.

 For ANSI style databases the access privilege set is not
 order-dependent.  The user matches the entry in the access
 privilege set and gets whatever privileges have been granted on
 the schema, table, or column and also gets the privileges
 defined for PUBLIC.  A user without an entry in the access
 privilege set will get only the privileges defined for PUBLIC.
 There is always an entry for PUBLIC in the access privilege set,
 even if PUBLIC has no access to the schema, table, or column.

column privs

 One or more of the following column privileges you want to add
 to an existing access privilege set entry or create in a new
 one:

 column-privs-ansi=

 ───┬─┬─┬─> 
U

P

D

A

T

E
─────┬─┬──┬──> │ │ └─> 
R

E

F

E

R

E

N

C

E

S
─┘ │ │ │ └─────── , <────────┘ │ └─────> 
A

L

L
typebox (P)typebox (R)typebox (I)typebox (V)typebox (I)typebox (L)typebox (E)typebox (G)typebox (E)typebox (S) ──┘ To grant all privileges to specified column(s), specify the ALL keyword instead of a list of privileges. Granting ANSI style privileges at the column, table, or schema level, grants access only to the columns, tables, or schema specified in the GRANT statement.

table privs

 One or more of the following table privileges you want to add to
 an existing access privilege set entry or create in a new one:

 table-privs-ansi=

 ─┬──┬─┬─> 
S

E

L

E

C

T
─────────────────────────────┬─┬──┬──> │ │ ├─> 
I

N

S

E

R

T
─────────────────────────────┤ │ │ │ │ ├─> 
O

P

E

R

A

T

O

R
───────────────────────────┤ │ │ │ │ ├─> 
D

E

L

E

T

E
─────────────────────────────┤ │ │ │ │ ├─> 
C

R

E

A

T

E

T

A

B
──────────────────────────┤ │ │ │ │ ├─> 
A

L

T

E

R
──────────────────────────────┤ │ │ │ │ ├─> 
D

R

O

P
───────────────────────────────┤ │ │ │ │ ├─> 
D

B

C

T

R

L
─────────────────────────────┤ │ │ │ │ ├─> 
S

H

O

W
───────────────────────────────┤ │ │ │ │ ├─> 
R

E

F

E

R

E

N

C

E

S
┬───────────────────────┤ │ │ │ │ │ └>( ┬> column-name ┬> )─┤ │ │ │ │ │ └───── , <─────┘ │ │ │ │ │ └─> 
U

P

D

A

T

E
─┬───────────────────────────┤ │ │ │ │ └>( ┬> column-name ┬────> )─┘ │ │ │ │ └───── , <─────┘ │ │ │ └─────────────────── , <────────────────────┘ │ └──────> 
A

L

L
typebox (P)typebox (R)typebox (I)typebox (V)typebox (I)typebox (L)typebox (E)typebox (G)typebox (E)typebox (S) ──────────────────────────┘ To grant all privileges to specified table(s), specify the ALL keyword instead of a list of privileges. Granting ANSI style privileges at the column, table, or schema level, grants access only to the tables, columns, or schema specified in the GRANT statement.

schema privs

 One or more of the following privileges you want to add to an
 existing access privilege set entry or create in a new one:

 schema-privs-ansi=

 ────┬───┬─┬─> 
S

E

L

E

C

T
─────┬─┬────┬─> │ │ ├─> 
I

N

S

E

R

T
─────┤ │ │ │ │ ├─> 
O

P

E

R

A

T

O

R
───┤ │ │ │ │ ├─> 
D

E

L

E

T

E
─────┤ │ │ │ │ ├─> 
C

R

E

A

T

E

T

A

B
──┤ │ │ │ │ ├─> 
A

L

T

E

R
──────┤ │ │ │ │ ├─> 
D

R

O

P
───────┤ │ │ │ │ ├─> 
D

B

C

T

R

L
─────┤ │ │ │ │ ├─> 
D

B

A

D

M
──────┤ │ │ │ │ ├─> 
S

H

O

W
───────┤ │ │ │ │ ├─> 
R

E

F

E

R

E

N

C

E

S
─┤ │ │ │ │ └─> 
U

P

D

A

T

E
─────┘ │ │ │ └────────, <────────┘ │ └───────> 
A

L

L
typebox (P)typebox (R)typebox (I)typebox (V)typebox (I)typebox (L)typebox (E)typebox (G)typebox (E)typebox (S) ────┘ To grant all privileges on the schema, specify the ALL keyword instead of a list of privileges. Granting ANSI style privileges at the column, table, or schema level, grants access only to the columns, tables, or schema specified in the GRANT statement. You must declare all schemas that you refer to in a GRANT statement. If you use the default schema declaration, you must use the authorization identifier RDB$DBHANDLE to work with the access privilege set for the schema.

identifier ansi style

 Specifies the identifiers for the new or modified access
 privilege set entry.

 identifier-ansi-style=

 ──────> uic-identifier ─────────>

 The identifiers are standard VMS identifiers.

 In ANSI style databases you are only allowed to specify
 single-user UICs.  No general or system identifiers are allowed.
 They identify only those users who are common to all the groups
 defined by the individual identifiers.  Users who do not match
 all the identifiers are not controlled by that entry.

 Specifying PUBLIC is equivalent to using the UIC identifier
 [*,*].

 When Rdb/VMS creates an ANSI style schema, the creator of the
 database gets all privileges and the PUBLIC entry gets no
 privileges.

WITH_GRANT_OPTION

 Allows the user who has been granted a privilege the option of
 granting that privilege to other users.

 The WITH GRANT OPTION clause specifies that the grantees in the
 TO clause may grant the privileges in the privilege list to
 other users for as long as they have the privileges.  When the
 privilege is revoked from the grantee who received the
 privileges with the WITH GRANT OPTION clause, the privileges
 will also be revoked from all the users who received the
 privileges from that grantee (unless these users have received
 the privilege from yet another user who still has the
 privilege).

Interactive kit

 If the interactive, rather than the development, version of the
 SQL distribution kit is installed on your system, you can run
 host language programs but cannot develop them.  You can create
 the sample database SQL_PERSONNEL on your system and try
 interactive examples in the SQL documentation set.  However, you
 cannot try out embedded, module language, or dynamic SQL
 examples because the SQL precompiler and SQL module processor
 are not part of the interactive version of SQL.

Linking programs

 When users link programs processed with either the SQL
 precompiler or the SQL module processor, they must somehow
 specify the SQL interface user library SYS$LIBRARY:SQL$USER.OLB.
 If you define the logical name LNK$LIBRARY as the user library,
 you save users from having to explicitly specify that library
 each time they link their embedded SQL programs.

 To define LNK$LIBRARY, issue this command:

 $ DEFINE/SYSTEM/NOLOG LNK$LIBRARY SYS$LIBRARY:SQL$USER.OLB

 To make sure LNK$LIBRARY is defined each time the system starts
 up, edit the command file SQL$STARTUP.COM and remove the comment
 character in front of the LNK$LIBRARY definition.

 You must also check to see that the system logical name
 LNK$LIBRARY is not already being used.  Your site or other
 products may have already defined the LNK$LIBRARY logical name.
 If so, you should add a numeric suffix to the LNK$LIBRARY
 definition you create and to the definition in SQL$STARTUP.COM.
 See the Rdb/VMS Installation Guide for more information about
 adding a suffix.

 If you do not define LNK$LIBRARY to specify the SQL user
 library, users must explicitly name it when they link programs
 with embedded SQL statements.  For example:

 $ LINK my_prog, SYS$LIBRARY:SQL$USER/LIBRARY

 See the VAX/VMS Linker Reference Manual for more information
 about the LINK command.

literals

 Literals, which are also called constants, specify a value.
 Many SQL clauses require literal values, which can be either
 numeric, character string, or date.  In addition, SQL provides
 two keywords, NULL and USER, that refer to literals.  NULL and
 USER are described in separate help topics.

Additional information available:

numericcharacter stringdate

numeric

 A numeric literal is a string of digits that SQL interprets as a
 decimal number.

 numeric-literal =

 ──┬──────┬─┬─┬─> digit ─┬─┬────────────────────────┬─┬─┐
   ├─> typebox (+) ─┤ │ └────<─────┘ └─> . ──┬───────>──────┬─┘ │ │
   └─> - ─┘ │                      └─┬─> digit ─┬─┘   │ │
            │                        └────<─────┘     │ │
            └─> . ─┬─> digit ─┬───────────────────────┘ │
                   └────<─────┘                         │
  ┌─────────────────────────────────────────────────────┘
  └┬──────────>─────────────────┬──>
   └── typebox (E) ─┬──────┬─┬─> digit ─┬─┘
          ├─> typebox (+) ─┤ └────<─────┘
          └─> - ─┘

Additional information available:

More InformationExamples

More Information

 A numeric literal may be:

  o  A decimal string consisting of digits and an optional
     decimal point.  The maximum length, not counting the decimal
     point, is 19 digits.

  o  A decimal number in scientific notation (E-format),
     consisting of a decimal string mantissa and a signed integer
     exponent, separated by the letter E or D (for G_Floating).

Examples

 SQL allows flexibility in numeric expressions.  You can use
 unary plus and minus, you can use any form of decimal notation,
 and you can embed spaces in E notation.  The following are valid
 numeric strings:

 123
 34.9
 -123
 .25
 123.
 0.33889909
 6.03E+23
 6.03E-23

 If you use a numeric literal to assign a value to a column or a
 variable, the data type of the column or variable determines the
 maximum value you can assign.

character string

 SQL recognizes two types of character string literals:

  o  A quoted character string to represent printable ASCII
     characters

  o  A hexadecimal character string (an X followed by a quoted
     character string) to represent printable and nonprintable
     ASCII characters

 See the section on literals in Chapter 3 of the Reference Manual
 for details.

date

 To refer to a date data type with a literal in an SQL statement,
 you must use the form dd-mmm-yyyy enclosed in single or double
 quotation marks.  SQL does not distinguish between upper- and
 lower-case characters in date literals.

 You can optionally include a complete or partial time component
 in addition to the day, month, and year.  The following diagram
 shows the format for a complete date literal with a time
 component:

 date-literal =

 ──> dd-mmm-yyyy ──┬────────────────────────────────────────┬─>
                   └─>   hh ──┬─────────────────────────────┤
                              └─> typebox (:)mm ──┬───────────────────┤
                                        └─> typebox (:)ss ──┬─────────┤
                                                  └─> .cc ──┘

 Note that date values stored in parameters must use a different
 format than for date literals.  See the Reference Manual section
 on data type conversion.

Module language

 MODULE  ─┬────────>────────┬─> 
L

A

N

G

U

A

G

E
language-name ─┐ └─> module-name ──┘ │ ┌──────────────────────────────────────────────────────┘ └─> 
A

U

T

H

O

R

I

Z

A

T

I

O

N
auth-id ──┬────────────>───────────┬─┐ └┬─> declare-statement ─┬┘ │ └───────── <───────────┘ │ ┌──────────────────────────────────────────────────────┘ └┬─> 
P

R

O

C

E

D

U

R

E
procedure-name ┬─> param-decl ┬─> typebox (;) sql-statement ; ─┬─> │ └─────── <─────┘ │ └─────────────────────────────── <─────────────────────────────────┘ param-decl = ─┬─> parameter ─┬─> data-type ───┬┬───────────────>─────────────┬─┬─> │ └─> domain-name ─┘└─> 
B

Y

D

E

S

C

R

I

P

T

O

R
┬─────>────┬┘ │ │ └─> 
C

H

E

C

K
─┘ │ ├─> 
S

Q

L

C

O

D

E
─────────────────────────────────────────────────────┤ ├─> 
S

Q

L

C

A
───────────────────────────────────────────────────────┤ └─┬───────>──────┬─> 
S

Q

L

D

A
──────────────────────────────────────┘ └─> parameter ─┘

Additional information available:

More InformationCommand line

More Information

 The SQL module language is a set of special keywords and syntax
 that allow procedures containing SQL statements to be called
 from any host language, including those not supported by the SQL
 precompiler.

 The SQL module language provides a calling mechanism for host
 language programs to execute SQL statements contained in a
 separate file called an SQL module file.  The file contains
 module language elements to specify a single SQL module.  The
 module includes one or more procedures, each of which contains
 parameter declarations and an SQL statement.

 The host language program uses call statements to specify a
 particular SQL module procedure and supplies a sequence of call
 parameters corresponding in number and in data type to the
 parameter declarations in the procedure.  A call to a procedure
 in an SQL module causes the SQL statement in the procedure to be
 executed.

Command line

 module-file-spec ─┬┬─────────────────────────────────────────────┬┬─>
                   │├─> typebox (/) ─┬──>───┬─┬─> 
O

B

J

E

C

T
─┬┬───────>───────┬┤│ ││ └─ 
N

O
─┘ ├─> 
L

I

S

T
───┘└> typebox (=) file-spec ─┘││ ││ ├─> 
V

I

D

A
─────────────────────┤│ ││ ├─> 
W

A

R

N
─────────────────────┤│ ││ ├─> 
F

L

A

G

typebox (N)typebox (O)typebox (N)typebox (S)typebox (T)typebox (A)typebox (N)typebox (D)typebox (A)typebox (R)typebox (D) ─────────┤│ ││ └─> 
G

F

L

O

A

T
──────────────────┤│ │├─> typebox (/)
C

O

N

S

T

R

A

I

N

T

S
typebox (=) ──┬─> 
O

N
──┬────────────────┤│ ││ └─> 
O

F

F
─┘ ││ │└─────────────────────────────────────────────┘│ └──────────────────────<────────────────────────┘

Additional information available:

More informationQualifiers

More information

 The SQL module processor is the executable image
 SYS$SYSTEM:SQL$MOD.EXE.  You can invoke it with the DCL RUN
 command or define a symbol to invoke the image.

 DCL RUN command:

 $ RUN SYS$SYSTEM:SQL$MOD
 INPUT FILE>

 Symbol:

 $ SQLMOD :== $SYS$SYSTEM:SQL$MOD
 $ SQLMOD
 INPUT FILE>

 If you invoke the SQL module processor without a file
 specification for an SQL module file, the module processor
 prompts you for the file specification.  You can also specify
 the file as part of the DCL command line.

Qualifiers

 module-file-spec:  The file specification for an SQL module
 source file.  The default file type for the source file is
 .SQLMOD.

 [NO]OBJECT:  Specifies whether or not the SQL module processor
 creates an object file when compilation does not generate fatal
 errors and, if an object file is produced, what the file is
 named.  /OBJECT is the default.

 [NO]LIST:  Determines whether or not the SQL module processor
 creates a listing file containing the original module listing
 along with any error messages from the processing, and, if it
 does, what it is named.  /NOLIST is the default.

 [NO]VIDA:  Specifies whether or not the SQL module processor
 will process a program for access to a VIDA database.  The
 default is /NOVIDA.

 [NO]WARN:  Specifies whether or not the SQL module processor
 writes informational and warning messages to your terminal, a
 listing file, or both.  /WARN is the default.

 [NO]FLAG:  Specifies whether SQL flags syntax that is not ANSI
 standard.  When /FLAG is specified, SQL notifies you of syntax
 that is not ANSI standard.  When /NOFLAG is specified, SQL does
 not notify you of syntax that is not ANSI standard.  The default
 is /NOFLAG.

 [NO]G_FLOAT:  Specifies whether or not the SQL module processor
 assigns a G-floating or D-floating interpretation to the DOUBLE
 data type in a formal parameter list.  /G_FLOAT is the default
 for all languages except COBOL.

 /CONSTRAINTS=ON or /CONSTRAINTS=OFF:  Sets the default
 constraint evaluation mode for commit-time constraints.  (This
 qualifier does not affect the evaluation of verb-time
 constraints.) The default is OFF:  that is, commit-time
 constraints are evaluated at commit time.  Setting constraints
 ON causes each of the affected constraints to be evaluated
 immediately, as well as at the end of each statement--until the
 SET ALL CONSTRAINTS OFF statement is issued or until the
 transaction completes with a commit or rollback operation.  This
 qualifier can be overridden by the SET ALL CONSTRAINTS
 statement.  SQL users who require ANSI standard SQL
 compatibility should set constraints ON.  The default of having
 constraints set OFF is probably acceptable for most other users.

New Features

 For more information about new features for SQL see the subtopic
 for the appropriate version.

 (Note that there is no Version 3.0 of VAX SQL.  VAX SQL Version
 2.0 was the last version where VAX SQL was shipped with a
 separate version number.  Beginning with Rdb/VMS Version 3.1,
 SQL is shipped with Rdb/VMS and assumes the Rdb/VMS version
 number.)

Additional information available:

V31

V31

 The following topics provide short summaries of new features for
 the SQL interface to Rdb/VMS Version 3.1.  See the release notes
 for VAX Rdb/VMS for details on new features for the SQL
 interface to Rdb/VMS.  Those release notes are available online
 in the file SYS$HELP:RDBVMS031.RELEASE_NOTES.

Additional information available:

DROP_CONSTRAINTSET_ALL_CONSTRAINTSWITH_GRANT_OPTION

Ada Host VariablesANSI Style PrivilegesAuto LockingDefault Values
Descending IndexesInternationalization SupportLanguage Sensitive Editor (LSE)
MiscellaneousPASCAL PrecompilerPRINT StatementRead Only System Relations
Referential IntegrityTriggersUNION operator

Ada Host Variables

 The Ada precompiler now allows users to define host variables
 used in SQL statements in terms of the definitions in another
 package.  This package is defined in the new ANSI standard for
 embedded SQL.  The name of the package is SQL_STANDARD, and its
 definition is in the file SYS$COMMON:[SYSLIB]SQL$STANDARD.ADA.
 Users must compile this package and add it to their library if
 they want to use it.

ANSI Style Privileges

 Users can specify whether ANSI style or ACL style privileges
 will be used.  ANSI style privileges are implemented through the
 PROTECTION IS ANSI clause of the CREATE SCHEMA statement and
 through the ANSI style versions of the GRANT and REVOKE
 statements.

 ANSI style databases:

 1.  Grant access to the creator when an object is created.
     Since only the creator is granted access to the newly
     created object, additional access must be granted
     explicitly.

 2.  Support only the PUBLIC identifier as a wildcard.

 3.  Support only rights identifiers that translate to a VMS User
     Identification Code (UIC).

Auto Locking

 You can specify auto-locking as an option with the RESERVING
 clause for the SET TRANSACTION statement (SQL).  Auto-locking
 causes tables referenced by constraints and triggers but not
 appearing in the RESERVING clause to be automaticaly locked when
 accessed from a constraint or trigger.

Default Values

 With Rdb/VMS V3.1, SQL allows you to specify a default value for
 a domain and/or for a column in a table.  If you specify a
 default value for a column in a table, it overrides any default
 value specified for the domain on which the column is based.

 The default value of a column is the value that is stored in the
 database if an insert operation on a row specifies no value for
 that column.  You might have any of several possible reasons for
 specifying a default value for a column; for instance, you may
 want to store the most commonly used value, or you may want to
 store a value that highlights (is visual displays) the fact that
 no value was stored.

 For information on specifying a default value, see the help on
 the CREATE DOMAIN, ALTER DOMAIN, CREATE TABLE, and ALTER TABLE
 statements.

Descending Indexes

 With Rdb/VMS V3.1, you can create descending indexes:  that is,
 indexes in which index keys are stored in descending (rather
 than the default ascending) sequence.  This capability can
 improve the performance of queries that retrieve records with
 high index key values.

 You can specify a descending index in SQL by using the DESC
 keyword with the CREATE INDEX statement.

DROP_CONSTRAINT

 Use the DROP CONSTRAINT statement to delete constraints that
 were defined with previous versions of SQL or with RDO (V3.1 or
 earlier).  There is no "CREATE CONSTRAINT" statement in SQL for
 Rdb/VMS V3.1; in SQL, contraints must be included in the table
 definition (CREATE TABLE or ALTER TABLE) -- for example, using
 the PRIMARY KEY keyword or CHECK clause with a column
 definition.

Internationalization Support

 Rdb/VMS V3.1 provides several options that are useful when the
 data in the database is not in English or when the user's
 primary language is not English.  These options fall into two
 categories:

  -  Statements to control the format of data for input and
     display of the currency indicator character, date and time
     format, digit separator character, radix point character,
     and the language used for various input and displays, such
     as day names, month names, and so on,

     The following list shows the new SQL statements relating to
     these formatting features:

      o  SET CURRENCY SIGN

      o  SET DATE FORMAT

      o  SET DIGIT SEPARATOR

      o  SET LANGUAGE

      o  SET RADIX POINT

      o  SHOW CURRENCY SIGN

      o  SHOW DATE FORMAT

      o  SHOW DIGIT SEPARATOR

      o  SHOW LANGUAGE

      o  SHOW RADIX POINT


  -  Collation sequence specification (to control sorting and
     comparisons)

     By default, Rdb/VMS uses the ASCII collation sequence for
     all sorting and Boolean operations; however, you can
     override this default by specifying one of the
     language-specific collation sequences supplied by the VMS
     National Character Set (NCS) Utility or a user-defined
     collation sequence using NCS.

     The following list shows the new SQL statements relating to
     collating sequences:

      o  CREATE COLLATION SEQUENCE

         Allows you to specify a collation sequence that has been
         defined using the NCS Utility.

      o  SHOW COLLATION SEQUENCES

         Displays the collation sequences for the declared
         schema.

      o  CREATE DOMAIN ...  COLLATION SEQUENCE

         Specifies a collation sequence for a new domain.

      o  ALTER DOMAIN ...  COLLATION SEQUENCE

         Specifies a new collation sequence for a domain.

      o  CREATE SCHEMA ...  COLLATION SEQUENCE

         Specifies a collation sequence that will be used for all
         columns in the schema.

      o  CREATE SCHEMA ...  CREATE COLLATION SEQUENCE

         Specifies a collation sequence that you can subsequently
         specify in a CREATE DOMAIN statment.

      o  IMPORT ...  COLLATION SEQUENCE

         Specifies a collation sequence that will be used for all
         columns in the schema.


Language Sensitive Editor (LSE)

 SQL now supports VAX Language Sensitive Editor (LSE) templates
 that guide you in entering correct SQL commands and statements.
 Rdb Version 3.1 includes support for two sets of LSE templates,
 one for interactive SQL and one for SQL Module Language.  The
 EDIT statement description in the Rdb/VMS SQL Referene Manual
 contains instructions on how to invoke the templates.

Miscellaneous

 The following VAX SQL statements and other language elements
 have the following additions and modifications for Rdb/VMS V3.1:

  -  SHOW PRIVILEGES now supports ANSI style protection

     SHOW PRIVILEGES shows which privileges are granted WITH
     GRANT OPTION and which privileges are not.

  -  Behavior of the OPEN cursor statement has changed

     Previously, if you opened a cursor, fetched a row, then
     opened the same cursor (that is, using the same name) and
     fetched a row, retrieval would start again at the first row,
     because the OPEN statement implicitly closed the cursor and
     reopened it.

     Now, if you do the same thing, retrieval after the second
     OPEN statement starts after the last row that was retrieved
     (for example, at row 2 if you only fetched one row before).
     This approach is ANSI compliant.

  -  New command line constraint syntax for the SQL precompiler

     You can optionally specify either
     /SQLOPTIONS=(CONSTRAINTS=ON) or
     /SQLOPTIONS=(CONSTRAINTS=OFF) on the SQL precompiler command
     line to set the default constraint evaluation mode for
     commit-time constraints.  (This qualifier does not affect
     the evaluation of verb-time constraints.) The default is
     OFF:  that is, commit-time constraints are evaluated at
     commit time.

     This qualifier can be overridden by the SET ALL CONSTRAINTS
     statement.

     It is expected that most Rdb/VMS users will accept the
     default that constraints are set OFF.  However, users who
     require ANSI standard SQL compatibility should set
     contraints ON.

  -  New command line constraint syntax for SQL module language

     You can optionally specify either /CONSTRAINTS=ON or
     /CONSTRAINTS=OFF on the SQL module language command line to
     set the default constraint evaluation mode for commit-time
     constraints.  (This qualifier does not affect the evaluation
     of verb-time constraints.) The default is OFF:  that is,
     commit-time constraints are evaluated at commit time.

     This qualifier can in turn be overridden by the SET ALL
     CONSTRAINTS statement.

     It is expected that most Rdb/VMS users will accept the
     default that constraints are set OFF.  However, users who
     require ANSI standard SQL compatibility should set
     contraints ON.

  -  SELECT

      -  Accepts the UNION operator

      -  Accepts the USER literal with views.


  -  CREATE DOMAIN and ALTER DOMAIN

      -  Accept the DEFAULT VALUE clause.

      -  Accept the CHECK and CONSTRAINT clauses.

      -  Accept the EDIT STRING clause.


  -  ALTER STORAGE AREA, ALTER SCHEMA (ALTER STORAGE AREA
     statement) -- accept the READ ONLY keyword


  -  CREATE INDEX -- accepts the DSC keyword.

  -  CREATE TABLE and ALTER TABLE:

      -  Accept the PRIMARY KEY keyword for a column or group of
         columns.

      -  Accept the REFERENCES clause for a column.

      -  Accept the DEFAULT VALUE clause.

      -  Accept the CHECK and CONSTRAINT clauses for a column.

      -  Accept the COLLATION SEQUENCE clause

      -  Accept the CONSTRAINT keyword.

         The DIAGNOSTIC keyword that was used in ALTER TABLE and
         CREATE TABLE statements in the previous version of SQL
         to define constraints has been replaced by the
         CONSTRAINT keyword.

         For example, in the previous version of SQL, you could
         define the following table using the DIAGNOSTIC keyword
         to define constraints:

         SQL> CREATE TABLE TEMP1
         cont> (COL1 REAL NOT NULL UNIQUE DIAGNOSTIC C1,
         cont>  COL2 REAL NOT NULL UNIQUE DIAGNOSTIC C2,
         cont>  COL3 REAL NOT NULL UNIQUE DIAGNOSTIC C3 );

         With the Rdb/VMS V3.1 SQL interface, you define the same
         table using the CONSTRAINT keyword to define
         constraints:

         SQL> CREATE TABLE TEMP1
         cont> (COL1 REAL NOT NULL UNIQUE CONSTRAINT C1,
         cont>  COL2 REAL NOT NULL UNIQUE CONSTRAINT C2,
         cont>  COL3 REAL NOT NULL UNIQUE CONSTRAINT C3 );

         Note that for Rdb/VMS V3.1, you can use either the
         CONSTRAINT or DIAGNOSTIC keyword in the ALTER TABLE and
         CREATE TABLE statements to define constraints.  However,
         you are encouraged to use CONSTRAINT, and to replace the
         DIAGNOSTIC keyword with CONSTRAINT in SQL command
         procedures that you expect to use with future versions
         of Rdb/VMS.


  -  CREATE VIEW -- accepts the WITH CHECK OPTION clause.

     Specifying WITH CHECK OPTION causes any data insertion or
     modification operation using a view to be validated against
     the view definition.

  -  ALTER STORAGE MAP -- accepts the REORGANIZE clause.

  -  CREATE SCHEMA

      -  Accepts the COLLATION SEQUENCE clause

      -  Accepts the DICTIONARY IS [NOT] USED clause.


  -  LIKE operator -- is now case sensitive by default; you can
     override by specifying case insensitive.  The LIKE operator
     also now includes support for the asterisk (*) character and
     the "escape" key.

  -  SHOW PRIVILEGES -- accepts the COLUMN ON column-name clause.

  -  Changes for ANSI ISO Compatibility

     Several changes have been made to VAX SQL to conform with
     the requirements of the ANSI ISO standard.

      o  For Rdb/VMS V3.0, SQL interpreted the value specified
         with the FLOAT data type as the number of decimal digits
         to be represented.  For Rdb/VMS V3.1.  the value
         specified is interpreted as the number of binary digits
         to be represented.

         Thus, the maximum precision is now 24 for REAL data and
         53 for DOUBLE PRECISION data.  (For V3.0, the maximum
         precisions were 7 and 15, respectively.)

      o  For Rdb/VMS V3.0, an attempt to open a cursor that is
         already opened generates a warning and an SQLCODE value
         of 1001.  For Rdb/VMS V3.1, this condition generates an
         error with an SQLCODE value of -502.

      o  For Rdb/VMS V3.1, the requirement that all SQL
         statements start with EXEC SQL is strictly enforced.
         Thus, the terms EXEC and SQL must be on the same line,
         and there must not be any comments between EXEC and SQL.
         (The EXEC SQL flag, however, is not required to be on
         the same line as the SQL statement it precedes.)

      o  For Rdb/VMS V3.1, the SQL$PRE precompiler supports ANSI
         COBOL format in addition to the previously supported
         terminal COBOL format.

      o  For Rdb/VMS V3.1, the SQL$PRE precompiler supports sign
         leading separate indicator variables in COBOL and
         longword indicator variables in Pascal.  (However, in
         dynamic SQL modules in Pascal, indicator variables must
         still be word length.) These enhancements are made to
         permit program conformance with ANSI requirements.

      o  With Rdb/VMS V3.0, SQL does not raise an error if a
         subquery in a value expression returns more than one
         value; rather, SQL simply returns the first value.  With
         Rdb/VMS V3.1, SQL returns an error in such cases, as
         required by the current ANSI standard.

         An example of a query whose behavior might change from
         V3.0 to V3.1 is:

            SQL> SELECT * FROM SPJ WHERE PNUM = (SELECT PNUM FROM
         P);

         Under V3.0, if (SELECT PNUM FROM P) returns more than 1
         row, the value of PNUM in the first row is returned.
         Unnder V3.1, an error is returned.

      o  ANSI requires a colon (:) before the label name in the
         GOTO clause of a WHENEVER statement.  In Rdb/VMS V3.0,
         SQL does did not allow the colon in this context.  In
         Rdb/VMS V3.1, SQL allows an optional colon in this
         context.  (Note that the colon is permitted only if the
         label is a name, not if it is a number.)


PASCAL Precompiler

 For Rdb/VMS V3.1, Pascal is added to the languages supported
 with the SQL$PRE precompiler.

 To precompile a Pascal program, use the following command:
 $ RUN SYS$SYSTEM:SQLPRE PASCAL_PROG/PASCAL

 The file type for the Pascal input file is .SPA.  When you
 precompile a Pascal program, the precompiler generates an output
 file with a file type .PAS.  You link and run Pascal host
 language programs in the same way as you link and run other host
 language programs.

PRINT Statement

 Use the PRINT statement to display a message to the user during
 execution of an SQL command procedure.  For example:
 ! Trigger definition statements are next.
 PRINT "Creating trigger definitions for the database";
 CREATE TRIGGER EMPLOYEE_ID_CASCADE_DELETE

Read Only System Relations

 You can change the RDB$SYSTEM storage area to be read-only, thus
 eliminating I/O operations that the Rdb/VMS software performs to
 update the system relations (primarily the cardinality values).
 However, while the RDB$SYSTEM storage area is read-only, you
 cannot make any changes to the metadata (that is, you cannot
 execute data definition language (DDL) statements), because the
 metadata is in that storage area.

 You make the RDB$SYSTEM storage read-only by specifying the
 schema/database rather than the storage area.  For example,
 using SQL, specify ALTER SCHEMA filename READ ONLY, and not
 ALTER STORAGE AREA RDB$SYSTEM READ ONLY.

 Making the RDB$SYSTEM storage area read-only may be appropriate
 and beneficial when the database is large, when improved
 application performance is important, and when you expect to
 make no further changes to the database metadata (or when such
 changes will be infrequent).

Referential Integrity

 Referential integrity refers to the consistency of related
 pieces of information across multiple tables in a database.
 Normally this involves ensuring the integrity of primary key and
 foreign key relationships.

 With Rdb/VMS V3.1, you can designate a column (or group of
 columns) in a table as the primary key.  The primary key
 uniquely identifies any row in the table; the primary key must
 contain values that are unique (no duplicates) and not null.
 You can also specify one or more columns in a table as having
 foreign key relationships:  that is, as referencing a column in
 another table.  If a column is so designated, then there must be
 at least one row in the other table with a matching column value
 for every row in this table (for example, a row in the EMPLOYEES
 table with an EMPLOYEE_ID column match for every row in the
 SALARY_HISTORY table).

SET_ALL_CONSTRAINTS

 The SET ALL CONSTRAINTS statement controls constraint checking
 for constraints that are evaluated at commit time.  (This
 statement has no effect on constraints that are evaluated at
 verb time.) A major use of the SET ALL CONSTRAINTS statement is
 to permit evaluation of these constraints at intervals before
 the transaction is committed.

 The default setting for SET ALL CONSTRAINTS statement is OFF
 (that is, constraint evaluation is deferred until commit time)
 -- unless you have specified otherwise with the /SQLOPTIONS or
 /CONSTRAINTS qualifier (both described later in this section).
 Specifying SET ALL CONSTRAINTS ON causes all of the affected
 constraints to be evaluated immediately, as well as at the end
 of each statement -- until the SET ALL CONSTRAINTS OFF statement
 is issued or until the transaction completes with a commit or a
 rollback.  If a transaction has been declared but is not active
 when the SET ALL CONSTRAINTS statement is executed, Rdb/VMS
 starts the declared transaction.

Triggers

 Rdb/VMS V3.1 includes the CREATE TRIGGER, DROP TRIGGER, and SHOW
 TRIGGER statements.

 A trigger is a definition that specifies one or more actions to
 be performed automatically whenever a certain operation is
 performed.  Triggers are often used to ensure that logically
 related operations involving multiple tables are done
 automatically at the same time, thus avoiding the risk of an
 inconsistent database and reducing the burden on programmers
 writing database applications.  For example, to ensure that all
 information related to an employee is deleted when an employee
 leaves the company, you can define a trigger specifying that
 whenever a row is deleted from the EMPLOYEES table, all rows
 with an EMPLOYEE_ID column match should also be deleted from the
 JOB_HISTORY, SALARY_HISTORY, and DEGREES tables -- this type or
 operation is sometimes called "cascading deletion." (In fact,
 such a trigger is defined in the sample database that you can
 create.)

 Triggers can be a very powerful mechanism.  They can make
 application development more efficient and enhance database
 consistency; however, if you are not careful or if you do not
 understand what you are doing, triggers can produce consequences
 you may not want.  Triggers should be used within a carefully
 designed system of update procedures, to ensure reproducible and
 consistent update and retrieval operations.

UNION operator

 The UNION operator is supported in SQL for Rdb/VMS V3.1.  When
 you want to combine the results of more than one query into one
 record stream, you can use the UNION operator.  With this
 operator, you can combine the values of columns in one table
 with the values of columns in other tables.

 For example, you can select all employees who are managers and
 all employees who have a PhD and combine the results into one
 table.
 SELECT EMPLOYEE_ID FROM CURRENT_JOB WHERE JOB_CODE = "DMGR"
 UNION
 SELECT EMPLOYEE_ID FROM DEGREES WHERE DEGREE="PhD";

 In the preceding example, if the CURRENT_JOB and the DEGREES
 tables list the same employee with the same EMPLOYEE_ID, the
 result table would display that employee's ID only once.
 Rdb/VMS selects rows from one query and then from the other
 query; however, you cannot make any assumptions as to which
 query Rdb/VMS performs first.  To specify the sort order, use
 the ORDER BY clause.

WITH_GRANT_OPTION

 The WITH GRANT OPTION clause of the GRANT statement allows the
 user who has been granted a privilege the option of granting
 that privilege to other users.

Precompiler

 SQL uses a single precompiler, SQL$PRE, to preprocess programs
 written in Ada, C, COBOL, FORTRAN, Pascal, and PL/I.  The
 precompiler lets you embed DML and DDL statements in programs
 that will access Rdb/VMS databases.  You can define symbols to
 invoke the precompiler for your host language:

      $ SADA :== $SYS$SYSTEM:SQL$PRE/ADA
      $ SCC  :== $SYS$SYSTEM:SQL$PRE/CC
      $ SCOB :== $SYS$SYSTEM:SQL$PRE/COBOL
      $ SFOR :== $SYS$SYSTEM:SQL$PRE/FORTRAN
      $ SPAS :== $SYS$SYSTEM:SQL$PRE/PLI
      $ SPLI :== $SYS$SYSTEM:SQL$PRE/PLI

Additional information available:

Command line

Command line

 host-file-spec ──> typebox (/) ─┬─> 
A

D

A
─────┬─┐ ├─> 
C

C
──────┤ │ ├─> 
C

O

B

O

L
───┤ │ ├─> 
F

O

R

T

R

A

N
─┤ │ ├─> 
P

A

S

C

A

L
──┤ │ └─> 
P

L

I
─────┘ │ ┌─────────────────<─────────────────┘ └┬┬─────────────────────────>─────────────────────────┬┬─> │├─> typebox (/) ─┬───>──┬──> 
O

B

J

E

C

T
─┬────────>───────┬───────┤│ ││ └─ 
N

O
─┘ └─> typebox (=) file-spec ─┘ ││ │├─> typebox (/) ─┬───>──┬──> 
G

F

L

O

A

T
─────────────────────────┤│ ││ └─ 
N

O
─┘ ││ │├─> typebox (/) 
S

Q

L

O

P

T

I

O

N

S
typebox (=) ( ─┬> opt-qualifiers ─┬> ) ───────┤│ ││ └─────── , <───────┘ ││ │└─> typebox (/) ─┬──────┬──> 
A

N

S

I
────────────────────────────┘│ │ └> 
N

O
─┘ │ └──────────────────────────<──────────────────────────┘ opt-qualifiers = ─┬─┬──>───┬┬─> 
V

I

D

A
─────────────┬───────┬─> │ └─ 
N

O
─┘├─> 
W

A

R

N
─────────────┤ │ │ └─> 
F

L

A

G

N

O

N

S

T

A

N

D

A

R

D
─┘ │ └─> 
C

O

N

S

T

R

A

I

N

T

S

=
─┬> 
O

N
─────────────┬─┘ └> 
O

F

F
─────────────┘

Additional information available:

More InformationQualifiers

More Information

 You can invoke the precompiler in one of two ways:

  o  Enter the input file name on the same line as the invoke
     command.

  o  Invoke the precompiler without an input file name and wait
     for the INPUT prompt to enter the input file name.

 The SQL$PRE precompiler accepts compile switches on the command
 line and at the INPUT prompt.  Precede all compile switches with
 a slash (/).  If you enter the compile switches on the command
 line, you can include compile switches ahead of the input file
 specification as well as after it.  Leave at least one space
 between the last switch and the input file specification.
 SQL$PRE does not prompt for compile switches.

 SQL$PRE produces two output files in your default directory:

  o  A host language source file

     The precompiler assigns the language default file type to
     the host language source file.  For example:

     Original source file:  PROGRAMB.SCO

     Host language source file:  PROGRAMB.COB

  o  An object file

     Object files have an .OBJ file type.  Using a compile
     switch, you can instruct SQL$PRE to write the object file to
     another directory.  For example, if SCOB is a symbol for
     "$SYS$SYSTEM:SQL$PRE/COBOL":

     $ SCOB PROGRAMC/OBJECT=$222$DISK3:[PAYROLL.OBJS]

 SQL$PRE lists the following information in the host language
 source file:

  o  Date and time the program was compiled

  o  Version of the precompiler used

  o  Underlying versions of Rdb/VMS, if any

  o  Command line used to precompile the program

  o  Precompile errors, if any

Qualifiers

 host-file-spec:  The file specification for a host language
 source file that contains embedded SQL statements.  The default
 file type for the source file depends on the host language
 specified in the language qualifier:

 Language          Default File Type
 --------          -----------------
 Ada               .SQLADA
 C                 .SC
 COBOL             .SCO
 FORTRAN           .SFO
 PL/I              .SPL

 ADA,CC,COBOL,FORTRAN,PASCAL,PLI:  Refers to the host language in
 which the program containing SQL statements is written.  You
 must supply a language qualifier.

 [NO]OBJECT:  Specifies whether or not the SQL precompiler
 creates an object file when compilation does not generate fatal
 errors and, if an object file is produced, what the file is
 named.  /OBJECT is the default.

 [NO]G_FLOAT:  Specifies whether or not the SQL precompiler
 assigns a G-floating or D-floating interpretation to the DOUBLE
 data type in a formal parameter list.  /G_FLOAT is the default
 for all languages except COBOL.

 /SQLOPTIONS=[NO]VIDA:  Specifies whether the SQL precompiler
 correctly processes a program for access to a VIDA database.  If
 you specify /SQLOPTIONS=VIDA, the precompiler will access the
 program for VIDA unless a specific DECLARE SCHEMA statement
 indicates NOVIDA.  If you do not specify VIDA in one of these
 places, but you try to access a VIDA database, you may get an
 error message.  If you do specify VIDA in these places, but
 attempt to access an Rdb/VMS database, then certain features
 will not work as expected for the current version of Rdb/VMS.
 The default is /SQLOPTIONS=NOVIDA.

 /SQLOPTIONS=[NO]WARN:  Specifies whether or not the SQL
 precompiler writes informational and warning messages to the
 preprocessed host language source file and to SYS$ERROR and
 SYS$OUTPUT (if different from SYS$ERROR).  SQLOPTIONS=WARN is
 the default.

 /SQLOPTIONS=[NO]FLAG:  Specifies whether SQL flags syntax that
 is not ANSI standard.  When FLAG is specified, SQL notifies you
 of syntax that is not ANSI standard.  When NOFLAG is specified,
 SQL does not notify you of syntax that is not ANSI standard.
 NOFLAG is the default.

 /SQLOPTIONS=(CONSTRAINTS=ON) and /SQLOPTIONS=(CONSTRAINTS=OFF):
 Sets the default constraint evaluation mode for commit-time
 constraints.  (This qualifier does not affect the evaluation of
 verb-time constraints.) The default is OFF:  that is,
 commit-time constraints are evaluated at commit time.  Setting
 constraints ON causes each of the affected constraints to be
 evaluated immediately, as well as at the end of each
 statement--until the SET ALL CONSTRAINTS OFF statement is issued
 or until the transaction completes with a commit or rollback
 operation.  This qualifier can be overridden by the SET ALL
 CONSTRAINTS statement.  SQL users who require ANSI standard SQL
 compatibility should set constraints ON.  The default of having
 constraints set OFF is probably acceptable for most other users.

 [NO]ANSI:  Specifies whether the SQL precompiler accepts
 terminal format COBOL or ANSI format COBOL.  The default is
 terminal format COBOL (NOANSI).

predicate

 predicate =
 ─┬─┬────────┬──┬─> basic-predicate ────────────────┬─┬──>
  │ └─> 
N

O

T
─┘ ├─> between-predicate ──────────────┤ │ │ ├─> containing-predicate ───────────┤ │ │ ├─> exists-predicate ───────────────┤ │ │ ├─> in-predicate ───────────────────┤ │ │ ├─> like-predicate ─────────────────┤ │ │ ├─> null-predicate ─────────────────┤ │ │ ├─> quantified-predicate ───────────┤ │ │ ├─> starting-with-predicate ────────┤ │ │ ├─> unique-predicate ───────────────┤ │ │ └─> (predicate) ────────────────────┘ │ │ │ └──────────────────┬─ 
A

N

D
<──┬──────────────────────┘ └── 
O

R
<──┘

Additional information available:

BETWEENCONTAININGEXISTSINLIKENULL
STARTING_WITHUNIQUE

More Informationbasiccomplexquantified

More Information

 A predicate follows the WHERE or HAVING keywords and specifies a
 condition that SQL evaluates as true, false, or unknown.
 Predicates are also called conditional expressions.  You can
 specify several different types of predicates with different
 conditional operators.  The different types of predicates are:

 Basic predicate
 BETWEEN predicate
 Complex predicate
 CONTAINING predicate
 EXISTS predicate
 IN predicate
 LIKE predicate
 NULL predicate
 Quantified predicate
 STARTING WITH predicate
 UNIQUE predicate

basic

 A basic predicate compares two values.  It has this form:

 basic-predicate =

 ────> value-expr ─┬─> typebox (=) ──┬─> value-expr ──>
                   ├─> <> ─┤
                   ├─> < ──┤
                   ├─> <typebox (=) ─┤
                   ├─> > ──┤
                   └─> >typebox (=) ─┘

 See the online HELP topic Value_expression for more information
 about value expressions.

BETWEEN

 A BETWEEN predicate compares a value with a range of values.  It
 has this form:

 between-predicate =

 ───> value-expr ─┬───>──┬─> 
B

E

T

W

E

E

N
value-expr AND value-expr ───> └> 
N

O

T
┘ As with IN predicates, BETWEEN predicates are a convenient way of representing conditions that have equivalent forms using other conditional operators: value1 BETWEEN value2 AND value3 is the same as the complex predicate (value1 >= value2) AND (value1 <= value3)

complex

 A complex predicate combines any number of predicates with the
 Boolean operators AND, OR, and NOT.  Boolean operators are also
 called logical operators.  A complex predicate has this form:

 complex-predicate =

 ─┬─┬─────────┬─┬───────┬─> predicate ──┬───────┬───┬───────────────>
  │ └─> 
N

O

T
──┘ └─> ( ──┘ └─> ) ──┘ ├─> 
A

N

D
──┬─┐ │ └─> 
O

R
───┘ │ └───────────────────────────<─────────────────────────────────┘

Additional information available:

More Information

More Information

 Note that you can, and occasionally must, set off predicates
 within a complex predicate with parentheses.  SQL evaluates
 parts of a complex predicate in this order:

  o  Predicates enclosed in parentheses
     (If there are nested predicates in parentheses, the
     innermost predicate is evaluated first.)

  o  Predicates preceded by NOT

  o  Predicates combined with AND

  o  Predicates combined with OR

CONTAINING

 A CONTAINING predicate tests whether the result table specified
 in the second value expression is found within the string
 specified by the first.  The CONTAINING predicate has this form:

 containing-predicate =

 ───> value-expr ─┬───>───┬─> 
C

O

N

T

A

I

N

I

N

G
──> value-expr ──> └> 
N

O

T
─┘ The CONTAINING predicate is not case sensitive.

EXISTS

 An EXISTS predicate tests whether the result table specified in
 a column select expression is empty.  It has this form:

 exists-predicate =

 ───> 
E

X

I

S

T

S
( col-select-expr ) ───> If the result table specified in the select expression has one or more rows, SQL evaluates the EXISTS predicate as true. Otherwise, the predicate is false. An EXISTS predicate cannot be unknown. Because it merely checks for the existence of rows, an EXISTS predicate allows a wildcard in the select list of the column select expression to specify a multicolumn table. It is the only type of predicate that allows this.

IN

 An IN predicate compares a value with another value or a
 collection of values.  It has this form:

 in-predicate =

 ──> value-expr ─┬────>───┬─> 
I

N
─┬─> value-expr ──────────────────────┬──> └─> 
N

O

T
─┘ └─> ( ─┬┬─> value-expr ─────┬┬─> ) ─┘ │└─> col-select-expr ─┘│ └────────── , <────────┘

Additional information available:

More Information

More Information

 For all the forms of IN predicates, there is an equivalent form
 using other conditional operators:


  o  value-expr IN value-expr

     is the same as the basic predicate

     value-expr = value-expr


  o  value-expr IN (value-expr1, value-expr2, value-expr3)

     is the same as the complex predicate

     value-expr = value-expr1
     OR
     value-expr = value-expr2
     OR
     value-expr = value-expr3


  o  value_expr IN (col-select-expr1, val-expr2,
     col-select-expr3)

     is the same as the quantified predicate

     value-expr = ANY (col-select-expr1)
     OR
     value-expr = val-expr2
     OR
     value expr = ANY (col-select-expr3)

LIKE

 A LIKE predicate searches character string literals for pattern
 matches.  The LIKE predicate is case-sensitive; it considers
 uppercase and lowercase forms of the same character to be
 different characters.  It has this form:

 like-predicate =

 ───> value-expr  ─┬───>──┬─> 
L

I

K

E
─────> pattern ──────>──────┐ └> 
N

O

T
┘ │ ┌────────────────────────────────<──────────────────────┘ └───┬────────────────────────────┬─> ├─> typebox (E)typebox (S)typebox (C)typebox (A)typebox (P)typebox (E) escape-character │ └─> typebox (I)typebox (G)typebox (N)typebox (O)typebox (R)typebox (E) typebox (C)typebox (A)typebox (S)typebox (E) ─────────────┘ pattern = ─┬─> string-literal ─┬───> ├─> 
U

S

E

R
───────────┤ └─> parameter ──────┘ Select More_Information to continue.

Additional information available:

More Information

More Information

 Because LIKE is case-sensitive, searches for uppercase
 multinational characters will not include lowercase
 multinational characters, and vice versa.

 SQL interprets the value-expr argument as a character string and
 compares it to the string literal, the value represented by the
 parameter, or the USER keyword (a 12-character string padded or
 truncated to the length of the column).

 Select More_Information to continue.

Additional information available:

More Information

More Information

 Within the string literal or value represented by the parameter
 or the USER keyword, the percent sign and underscore characters
 have special meaning:

  o  The percent sign character (%) stands for any string of
     characters, including no characters at all.

  o  The underscore character (_) stands for any single
     character.

  o  An escape character causes SQL to interpret a wildcard
     character as itself to search for character strings
     containing the wildcard character.

 All other characters stand for themselves.

 You cannot specify both the IGNORE CASE and the ESCAPE keywords
 in the same boolean.

NULL

 A NULL predicate tests for null values in value expressions.  It
 has this form:

 null-predicate =

 ────> value-expr ───> 
I

S
─┬────>───┬─> 
N

U

L

L
───> └─> 
N

O

T
─┘ SQL never evaluates a NULL predicate as unknown: it is always true or false. If the value expression is null, SQL evaluates the predicate as true. If the value expression is not null, the predicate is false. Note that NULL predicates are the only way to construct a query that includes rows in a result table by testing whether the rows have null values. Other constructions such as NOT = or <> do not include rows with null values in their result tables.

quantified

 A quantified predicate compares a value with a collection of
 values.  It has the same form as a basic predicate except that
 the second operand must be a column select expression preceded
 by ALL, ANY, or SOME:

 quantified-predicate =

 ───> value-expr ─┬─> typebox (=) ──┬─┬─> 
A

L

L
──┬─> ( col-select-expr ) ──> ├─> <> ─┤ ├─> 
A

N

Y
──┤ ├─> < ──┤ └─> 
S

O

M

E
─┘ ├─> <typebox (=) ─┤ ├─> > ──┤ └─> >typebox (=) ─┘ If you use ALL, then SQL evaluates the predicate as true if the relationship is true for every row of the result table specified by the column select expression or if the result table has no rows. If you use ANY or SOME (both keywords have the same effect), SQL evaluates the predicate as true if the relationship is true for at least one of the rows in the result table specified by the column select expression.

STARTING_WITH

 starting-with-predicate =

 ──> value-expr ─┬──>───┬─> 
S

T

A

R

T

I

N

G

W

I

T

H
──> value-expr ──> └ 
N

O

T
─┘ The STARTING WITH predicate tests whether the first characters of the first value expression match those specified in the second value expression. The STARTING WITH predicate is case sensitive.

UNIQUE

 unique-predicate=

 ───> 
U

N

I

Q

U

E
──> (col-select-expr) ───> The UNIQUE predicate tests whether the result table specified in the select expression has only one row. If it has only one row, SQL evaluates the UNIQUE predicate as true. Otherwise, the predicate is false. SQL evaluates the NOT UNIQUE predicate as true if the result table specified in the select expression has more than one row. The UNIQUE and NOT UNIQUE predicates cannot be unknown. Because it merely checks for the existence of rows, a UNIQUE predicate does not require that the result table from its column select expression be a single column wide. For UNIQUE predicates, an asterisk wildcard in the column select expression can refer to a multicolumn table.

Release Notes

 The release notes for the SQL interface to Rdb/VMS are part of
 the VAX Rdb/VMS Release Notes, which are available online in
 this file:

          SYS$HELP:RDBVMSvvu.RELEASE_NOTES

          where       vv  = version
                        u = update

 For example:

          SYS$HELP:RDBVMS031.RELEASE_NOTES

 Published release notes may differ from the online release notes
 because the latest information was not available at publication
 time.  Therefore, you should also read the online release notes
 to see if additional notes have been added since the printed
 version.

REVOKE ANSI style

 Removes privileges from an entry in a database, table, or column
 access privilege set.

 REVOKE ───────────────────────┐
                               │
  ┌─────────────<──────────────┘
  └┬─> schema-privs-ansi ──────> 
O

N

S

C

H

E

M

A
typebox (A)typebox (U)typebox (T)typebox (H)typebox (O)typebox (R)typebox (I)typebox (Z)typebox (A)typebox (T)typebox (I)typebox (O)typebox (N) ─┬─> auth-id ─┬─┬─┐ │ └───── , <───┘ │ │ ├─> table-privs-ansi ──> 
O

N
─┬───────────┬┬─> table-name ──┬──────────┤ │ │ └─> 
T

A

B

L

E
──┘└─> view-name ───┘ │ │ │ │ │ └─> column-privs-ansi ──────> 
O

N

C

O

L

U

M

N
──┬─> column-name ──┬─────────┘ │ └─────── , <──────┘ │ ┌──────────────────────────<───────────────────────────────────────────┘ └─> 
F

R

O

M
─┬─┬─> identifier-ansi-style ─┬─────────────────────┬───> typebox (;) │ └─> 
P

U

B

L

I

C
────────────────┘ │ └──────────────────── , <──────────────────────────┘

Additional information available:

More Informationcolumn privs ansitable privs ansischema privs ansi
identifier ansi style

More Information

 The REVOKE statement removes privileges from the Rdb/VMS access
 privilege set for a database, table, or column.  Each entry in
 an access privilege set consists of an identifier and a list of
 privileges assigned to the identifier:

  o  Each identifier specifies a user or PUBLIC.

  o  The set of privileges specifies what operations that user or
     user group can perform on the database or table.

 For ANSI style databases the access privilege set is not
 order-dependent.  The user matches the entry in the access
 privilege set and gets whatever privileges have been granted on
 the schema, table, or column and also gets the privileges
 defined for PUBLIC.  A user without an entry in the access
 privilege set will get only the privileges defined for PUBLIC.
 There is always an entry for PUBLIC in the access privilege set,
 even if PUBLIC has no access to the schema, table, or column.

Additional information available:

More Information

More Information

 When a privilege is revoked from the grantee who received the
 privilege with the WITH GRANT OPTION clause, the privilege will
 also be revoked from all the users who received the privilege
 from that grantee (unless these users have received the
 privilege from yet another user who still has the privilege).

column privs ansi

 One or more of the following column privileges you want to
 remove from an existing access privilege set entry or create in
 a new one:

 column-privs-ansi=

 ───┬─┬─┬─> 
U

P

D

A

T

E
─────┬─┬──┬──> │ │ └─> 
R

E

F

E

R

E

N

C

E

S
─┘ │ │ │ └─────── , <────────┘ │ └─────> 
A

L

L
typebox (P)typebox (R)typebox (I)typebox (V)typebox (I)typebox (L)typebox (E)typebox (G)typebox (E)typebox (S) ──┘ To revoke all privileges from the specified column(s), specify the ALL keyword instead of a set of privileges. You can only revoke column level privileges that have been specifically granted at the column level.

table privs ansi

 One or more of the following table privileges you want remove
 from an existing access privilege set entry or create in a new
 one:

 table-privs-ansi=

 ─┬──┬─┬─> 
S

E

L

E

C

T
─────────────────────────────┬─┬──┬──> │ │ ├─> 
I

N

S

E

R

T
─────────────────────────────┤ │ │ │ │ ├─> 
O

P

E

R

A

T

O

R
───────────────────────────┤ │ │ │ │ ├─> 
D

E

L

E

T

E
─────────────────────────────┤ │ │ │ │ ├─> 
C

R

E

A

T

E

T

A

B
──────────────────────────┤ │ │ │ │ ├─> 
A

L

T

E

R
──────────────────────────────┤ │ │ │ │ ├─> 
D

R

O

P
───────────────────────────────┤ │ │ │ │ ├─> 
D

B

C

T

R

L
─────────────────────────────┤ │ │ │ │ ├─> 
S

H

O

W
───────────────────────────────┤ │ │ │ │ ├─> 
R

E

F

E

R

E

N

C

E

S
┬───────────────────────┤ │ │ │ │ │ └>( ┬> column-name ┬> )─┤ │ │ │ │ │ └───── , <─────┘ │ │ │ │ │ └─> 
U

P

D

A

T

E
─┬───────────────────────────┤ │ │ │ │ └>( ┬> column-name ┬────> )─┘ │ │ │ │ └───── , <─────┘ │ │ │ └─────────────────── , <────────────────────┘ │ └──────> 
A

L

L
typebox (P)typebox (R)typebox (I)typebox (V)typebox (I)typebox (L)typebox (E)typebox (G)typebox (E)typebox (S) ──────────────────────────┘ To revoke all privileges from the specified table(s), specify the ALL keyword instead of a list of privileges.

schema privs ansi

 One or more of the following privileges you want to remove from
 an existing access privilege set entry or create in a new one:

 schema-privs-ansi=

 ────┬───┬─┬─> 
S

E

L

E

C

T
─────┬─┬────┬─> │ │ ├─> 
I

N

S

E

R

T
─────┤ │ │ │ │ ├─> 
O

P

E

R

A

T

O

R
───┤ │ │ │ │ ├─> 
D

E

L

E

T

E
─────┤ │ │ │ │ ├─> 
C

R

E

A

T

E

T

A

B
──┤ │ │ │ │ ├─> 
A

L

T

E

R
──────┤ │ │ │ │ ├─> 
D

R

O

P
───────┤ │ │ │ │ ├─> 
D

B

C

T

R

L
─────┤ │ │ │ │ ├─> 
D

B

A

D

M
──────┤ │ │ │ │ ├─> 
S

H

O

W
───────┤ │ │ │ │ ├─> 
R

E

F

E

R

E

N

C

E

S
─┤ │ │ │ │ └─> 
U

P

D

A

T

E
─────┘ │ │ │ └────────, <────────┘ │ └───────> 
A

L

L
typebox (P)typebox (R)typebox (I)typebox (V)typebox (I)typebox (L)typebox (E)typebox (G)typebox (E)typebox (S) ────┘ To revoke all privileges on the schema, specify the ALL keyword instead of a set of privileges. You must declare all schemas that you refer to in a REVOKE statement. If you use the default schema declaration, you must use the authorization identifier RDB$DBHANDLE to work with the access privilege set for the schema.

identifier ansi style

 Specifies the identifiers for the new or modified access
 privilege set entry.

 identifier-ansi-style=

 ──────> uic-identifier ─────────>

 The identifiers are standard VMS identifiers.

 In ANSI style databases you are only allowed to specify
 single-user UICs.  No general or system identifiers are allowed.
 They identify only those users who are common to all the groups
 defined by the individual identifiers.  Users who do not match
 all the identifiers are not controlled by that entry.

 Specifying PUBLIC is equivalent to using the UIC identifier
 [*,*].

 When Rdb/VMS creates an ANSI style schema, the creator of the
 database gets all privileges and the PUBLIC entry gets no
 privileges.

Sample Databases

 You can create a sample database that is referred to throughout
 the Rdb/VMS documentation.

 You use a single command procedure to build all varieties of the
 sample personnel database.  To create your own copy using
 SQL-based or RDO-based procedures, type the following:

       $ @RDM$DEMO:PERSONNEL.COM <p1> <p2> <p3>

 The procedure accepts three parameters, all optional.

    p1 = interface language      SQL or RDO
    p2 = type of database        S (single-file) or M (multifile)
    p3 = dictionary use          CDD (yes) or NOCDD (no)

 If you specify no parameters, the default is an SQL single-file
 database with no dictionary.

 The single-file database occupies approximately 2200 disk
 blocks.  The multifile version of the same database occupies
 about 2900 disk blocks.

 If you want to specify p2, you must specify p1; and if you want
 to specify p3, you must specify both p1 and p2.

select expr

 select-expr =

 ───┬─┬─> select-clause ─────┬───>
    │ └─>( select-expr ) ────┤
    │ ┌─────────<────────────┘
    │ └─>
U

N

I

O

N
─┬───────┬────┐ │ └─>
A

L

L
─┘ │ └───────<────────────────┘

Additional information available:

FROMWHEREGROUP_BYHAVINGUNION

More Informationselect clauseselect list

More Information

 The basic element of SQL syntax is the select expression.
 Select expressions are the basis for the SELECT, DECLARE CURSOR,
 CREATE VIEW, and INSERT statements.  Select expressions specify
 a result table.  A result table is a temporary table derived
 from some combination of the tables or views identified in the
 FROM clause of the statement.

select clause

 select-clause =

 SELECT ─┬──────>──────┬─> select-list ──┐
         ├─> 
A

L

L
──────┤ │ └─> 
D

I

S

T

I

N

C

T
─┘ │ ┌──────────────────────────────<──────┘ └ 
F

R

O

M
─┬┬─> table-name ─┬─┬─────>────┬─┬─┬─────────>──────────┬─┐ │└─> view-name ──┘ └─> alias ─┘ │ └─> 
W

H

E

R

E
predicate ─┘ │ └────────── , <─────────────────┘ │ ┌──────────────────────────────<─────────────────────────────────┘ └┬─────────────>──────────────────┬─┬──────────>──────────┬──> └─> 
G

R

O

U

P

B

Y
─┬─> column-name ─┬─┘ └─> 
H

A

V

I

N

G
predicate ─┘ └─────── , <─────┘

Additional information available:

More Information

More Information

 SQL evaluates the arguments in a select clause in the following
 order:

  o  FROM

  o  WHERE

  o  GROUP BY

  o  HAVING

  o  select-list

 After each of these clauses, SQL logically produces an
 intermediate result table that is used in evaluation of the next
 clause.

select list

 Identifies a list of column names and value expressions (to be
 derived from the tables and views named in the FROM clause) for
 the result table.

 select-list =

 ───┬─────────────> typebox (*) ────────────────┬───>
    └─┬─┬─┬─> table-name ─┬─> .typebox (*) ─┬─┬─┘
      │ │ ├─> view-name ──┤       │ │
      │ │ └─> alias ──────┘       │ │
      │ └───> value-expr ─────────┘ │
      └──────────── , <─────────────┘

Additional information available:

More Information

More Information

 You can use asterisks as wildcards in a select list:

 SELECT *

 Tells SQL to use all the column names from the intermediate
 result table (namely, all the columns in all the tables and
 views referred to in the FROM clause).  If the select expresion
 contains a GROUP BY clause, SQL interprets the wildcard as
 specifying only the columns named in the GROUP BY clause.

 SELECT name.*

 Qualifying an asterisk with a table name, view name, or alias
 tells SQL to use all the columns in the table or view referred
 to by the name.  The name must be specified in the FROM clause
 of the select expression.  You cannot mix this form of wildcard
 notation with the previous two.  The number of columns you
 specify in the select list, either with wildcards or by
 explicitly listing value expressions, is the number of columns
 in the result table.

FROM

 Identifies the tables and views that SQL uses to generate the
 result table.  If you name more than one table or view, SQL
 joins them to create an intermediate result table.  That
 intermediate table consists of every possible combination of all
 the rows and columns of each table (the Cartesian product).

 You can specify an alias following a table or view name in the
 FROM clause to qualify column names in other parts of the select
 expression.  If you do not explicitly specify an alias, SQL
 implicitly specifies the table name or view name as an alias.
 Do not specify the same alias more than once, either explicitly
 or implicitly.

WHERE

 Specifies a predicate that SQL evaluates to generate an
 intermediate result table.  SQL evaluates the predicate for each
 row of the intermediate result table created by the FROM clause.
 The rows of that table for which the predicate is true become
 another intermediate result table for later clauses in a select
 expression.  Column names specified in the predicate of the
 WHERE clause must either:

  o  Identify columns of the intermediate result table created by
     the FROM clause

  o  Be an outer reference (possible only if the WHERE clause is
     part of a column select expression)

 The predicate in a WHERE clause cannot refer to a function.

GROUP_BY

 Indicates the column names that SQL uses for partitioning the
 intermediate result table from the WHERE clause, if specified,
 or the FROM clause.  For the first column specified in the GROUP
 BY clause, SQL rearranges the rows of the preceding intermediate
 result table into groups whose rows all have the same value for
 the specified column.  If there is a second column specified in
 the GROUP BY clause, SQL then groups rows within each main group
 by values of the second column.  SQL groups by any additional
 columns in the GROUP BY clause in a similar manner.  All null
 values for a column name in the GROUP BY clause are grouped
 together.

 Each group is treated as the source for the values of a single
 row of the result table.

 Since there is no single value for columns not specified in the
 GROUP BY clause, references to column names not specified in
 GROUP BY must be within a function.  Because all the rows of a
 group have the same value for the column specified in the GROUP
 BY clause, references within value expressions or predicates to
 that column specify a single value.

HAVING

 Specifies a predicate SQL evaluates to generate an intermediate
 result table.  SQL evaluates the predicate for each group of the
 intermediate result table created by the preceding clause.  The
 groups of that table for which the predicate is true become
 another intermediate result table, if there is an ORDER BY
 clause in a SELECT statement.  Otherwise, the result table from
 a HAVING clause is the final result table for the select
 expression.

 Typically, the clause preceding the HAVING clause is a GROUP BY
 clause.  The predicate is then evaluated for each group in the
 intermediate result table.  The HAVING clause affects groups as
 the WHERE clause affects individual rows.

 If the HAVING clause is not preceded by a GROUP BY clause, SQL
 evaluates the predicate for all the rows in the intermediate
 result table as a single group.

Additional information available:

Restriction

Restriction

 SQL restricts which columns you can specify in the predicate of
 a HAVING clause.  Column names in a HAVING predicate must meet
 one of the following conditions:

  o  Also be in the GROUP BY clause

  o  Be specified within a function

  o  Be an outer reference (possible only if the HAVING clause is
     part of a column select expression)

UNION

 The union operator merges the results of a select expression or
 select clause with another select expression or select clause
 into one result table by appending the values of columns in one
 table with the values of columns in other tables.

Additional information available:

ALL

ALL

 The ALL qualifier specifies that duplicate rows should not be
 eliminated from the result table.

singleton select

 singleton-select =

 SELECT ─┬──────>──────┬─> select-list ──┐
         ├─> 
A

L

L
──────┤ │ └─> 
D

I

S

T

I

N

C

T
─┘ │ ┌─────────────────────────────────────┘ └─> typebox (I)typebox (N)typebox (T)typebox (O) ──┬─> parameter ─┬─┐ └────── , <────┘ │ ┌───────────────────────────┘ └ 
F

R

O

M
─┬┬─> table-name ─┬─┬─────>────┬─┬─┬─────────>──────────┬─┐ │└─> view-name ──┘ └─> alias ─┘ │ └─> 
W

H

E

R

E
predicate ─┘ │ └────────── , <─────────────────┘ │ ┌──────────────────────────────<─────────────────────────────────┘ └┬─────────────>──────────────────┬─┬──────────>──────────┬──> └─> 
G

R

O

U

P

B

Y
─┬─> column-name ─┬─┘ └─> 
H

A

V

I

N

G
predicate ─┘ └─────── , <─────┘

Additional information available:

INTO

More Information

More Information

 A singleton select statement is a special form of the SELECT
 statement that is legal only in programs, not in interactive
 SQL.  A singleton select specifies a one-row result table.  It
 includes an additional clause, INTO, to assign the values in the
 row to parameters in a program.

INTO

 Names parameters representing program storage that will receive
 values from the columns of the one-row result table.  If a
 parameter named in the list is corresponds to a program host
 structure, SQL considers the reference the same as a reference
 to each of the elements of the host structure.

 If the number of parameters specified, either explicitly or by
 reference to a host structure, does not match the number of
 values in the row of the result table, SQL generates an error
 when it precompiles the program or processes the SQL module
 containing the singleton select statement.

 If columns in the result table from a singleton select include
 null values, the corresponding parameters must include indicator
 parameters.

Value expression

 value-expr =

 ─┬─┬──────┬─┬─> column-name ──────────────────────────┬─┬──────────>
  │ ├─> typebox (+) ─┤ ├─┬─> 
S

U

M
───┬┬─> (
D

I

S

T

I

N

C

T
column-name) ─┤ ├─> typebox (+) ─┬─┐ │ └─> - ─┘ │ ├─> 
A

V

G
───┤└─> (typebox (A)typebox (L)typebox (L) value-expr) ───────┤ ├─> - ─┤ │ │ │ ├─> 
M

A

X
───┤ │ ├─> typebox (*) ─┤ │ │ │ └─> 
M

I

N
───┘ │ └─> typebox (/) ─┘ │ │ ├───> 
C

O

U

N

T
─┬──> (typebox (*)) ────────────────────┤ │ │ │ └──> (
D

I

S

T

I

N

C

T
column-name) ─┤ │ │ ├─> literal ──────────────────────────────┤ │ │ ├─> 
U

S

E

R
─────────────────────────────────┤ │ │ ├─> parameter ────────────────────────────┤ │ │ ├─> 
D

B

K

E

Y
────────────────────────────────┤ │ │ ├─> (col-select-expr) ────────────────────┤ │ │ └─> (value-expr) ─────────────────────────┘ │ └──────────────────────────────<────────────────────────────────┘

Additional information available:

More Information

More Information

 A value expression is a symbol or string of symbols used to
 represent or calculate a single value.  When you use a value
 expression in a statement, SQL retrieves or calculates the value
 associated with the expression and uses that value when
 executing the statement.

 Value expressions are also called scalar expressions or simply
 expressions.

 Select More_Information to continue.

Additional information available:

More Information

More Information

 There are several different types of value expressions:

  o  A column name represents a value in table rows.

  o  A function calculates values for every row of a result
     table.  SQL functions are SUM, AVG, MAX, MIN, and COUNT.

  o  A literal directly specifies a value.

  o  A parameter represents a value in a host program.

  o  The DBKEY keyword represents the value of an internal
     pointer, called a database key, to a table row.

  o  A column select expression used as a value expression
     specifies a one-value result table.

 You can also combine certain value expressions with arithmetic
 operators to form value expression.

 Literals, functions, DBKEYS and column select expressions are
 described in separate Help topics.

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026