Žๆฅญจโฅ ํโฎโ โฅชแโ:


Dƒš SQL ”ฎเฌ โ ฎฏฅเ โฎเฎข  ƒŠ  E2 แโเ. ฏฎ D86E แโเฎชD  ƒŠ Eไ ฉซD  hsql  ƒšE
ƒšDŽฏเฅคฅซฅญจ๏E    CREATE, DROP, DATABASE, ALTER, RENAME         ƒš
ƒšDŒ ญจฏใซ๏ๆจจE    DELETE, INSERT, UPDATE, LOAD/UNLOAD           ƒš
ƒš               SELECT and UNION statements.                  ƒš
ƒšD„ฎแโใฏ E        GRANT/REVOKE, LOCK/UNLOCK, SET LOCK MODE      ƒš
ƒšD‚ฎแแโ ญฎขซฅญจ๏E Transaction, Audit trail                      ƒš
ƒšDเฎ็จฅE         CHECK, REPAIR, INFO, OUTPUT, SET EXPLAIN      ƒš
ƒ“ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ›ƒ”
Dƒƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‚E
DƒŠDefinition     CREATE, DROP, DATABASE, ALTER, RENAME       ƒŠE
DƒŠE  Žฏฅเ โฎเ๋ ฎฏเฅคฅซฅญจ๏ ค ญญ๋ๅ ญฅ ฎโช โ๋ข ๎โแ๏             DƒŠE
Dƒƒƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ„E
DCREATE DATABASEE database [WITH LOG IN "pathname" [MODE ANSI]]

DDROP DATABASEE database-name       แโ ญค เโ  ansi = โเฅกใฅโ
                        จฌ๏ ขซ คฅซ์ๆ , โเ ญง ชๆจ๏ ฏฎ ใฌฎซ็ญจ๎

DDATABASEE database-name [EXCLUSIVE]      แคฅซ โ์ โฅชใ้ฅฉ
DCLOSE DATABASEE

DCREATEE [TEMP] DTABLEE table-name ( column-name datatype [NOT NULL]
                         [UNIQUE [CONSTRAINT constr-name]][,...] )
        [UNIQUE(uniq-col-list) [CONSTRAINT constr-name]][,..]
        [WITH NO LOG]
        [IN "pathname-directory"]

                DATA TYPES
    INTEGER     SERIAL[(n0)] -  ขโฎฌ โจ็ฅแชจฉ แ็ฅโ็จช
    SMALLINT    CHAR(n)        DATE
    FLOAT       DECIMAL(m,n)   DATETIME qualif1 TO qualif2
    REAL        MONEY(m,n)     INTERVAL qualif1 TO qualif2
ฃคฅ qualifier จ {YEAR,MONTH,DAY,HOUR,MINUTE,SECOND,FRACTION(n)}

DALTER TABLEE table-name
     {  ADD ( new-column-name datatype [NOT NULL]
                [UNIQUE [CONSTRAINT constr-name]][,...] )
        |           [BEFORE old-column-name]
        DROP (old-column-name[,...])
        |
        MODIFY (old-column-name new-datatype [NOT NULL][,...])
        |
        ADD CONSTRAINT UNIQUE (old-column-name[,...])
        |                          [CONSTRAINT constr-name]
        DROP CONSTRAINT (constr-name[,...])      } [,...]

DCREATE VIEWE view-name [(column-list)]
        AS SELECT-statement [WITH CHECK OPTION]

DCREATEE [UNIQUE|DISTINCT] [CLUSTER] DINDEXE index-name
        ON table-name (column-name [DESC], ...)

DALTER INDEXE index-name TO [NOT] CLUSTER  Cโเฎชจ ข ฏฎเ๏คชฅ จญคฅชแ 

CREATE SCHEMA AUTHORIZATION username {create and/or grant statements}
   เจฌฅ็ ญจฅ:  ฏฎค็ฅเชญใโ๋ฅ ฎฏฅเ โฎเ๋ ญฅซ์ง๏ จแฏฎซ์งฎข โ์ ข 4GL  
DCREATE SYNONYME synonym-name FOR table-name

DDROP INDEXE index-name
DDROP SYNONYME synonym-name
DDROP TABLEE table-name
DDROP VIEWE view-name

DRENAME TABLEE old-table-name TO new-table-name
DRENAME COLUMNE table.old-column-name TO new-column-name

Dƒƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‚E
DƒŠ  Manipulation  DELETE, INSERT, UPDATE, LOAD, UNLOAD       ƒŠE
Dƒƒƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ„E
DDELETE FROME table-name [WHERE condition]

DINSERT INTOE table-name [(column-list)]
      { VALUES (value-list) |  SELECT-statement }

DUPDATEE table-name DSETE {column-name ={ expression | (SELECT-st) } [,...]   |
 {(col-list) | [table.]*} =
 { ({ expr-list | (SELECT-st) } [,...]) | record-name.* }
     [WHERE  condition]

DLOAD FROME "file" [DELIMITER "?"] INSERT INTO table [(col-list)]
DUNLOAD TOE "file" [DELIMITER "?"] SELECT-statementDƒƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‚E
DƒŠ    Select        The SELECT and UNION statements.         ƒŠE
Dƒƒƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ„E
DSELECTE [UNIQUE] select-list
        [FROM { [OUTER] tabname [tab-alias] |
           OUTER (table-expr) } [,...]  ]
        [WHERE condition]
        [GROUP BY column-list] [HAVING condition]
        [ORDER BY column-name [DESC],...]
        [INTO TEMP table-name]

SELECT-statement UNION [ALL] SELECT-statement  [. . .]

     WHERE conditions:

  แข๏ง ญญ๋ฅ ซฎฃจ็ฅแชจฌจ ฎฏฅเ โฎเ ฌจ OR, AND, NOT แเ ขญฅญจ๏

        expr rel-op expr        ฃคฅ rel-op จง  >,<,>=,<=,<>,!=
        column-name IS [NOT] NULL
        expr [NOT] BETWEEN ... AND ...
        expr [NOT] IN (.. , ..  [, ...] )

                                   ฏฎ ใฌฎซ็ ญจ๎ "\"
        string [NOT] LIKE "่ กซฎญ" [ESCAPE "escape-char"]
         แฏฅๆแจฌขฎซ๋ ่ กซฎญ   D%E D_E  ฎงญ ็ ๎โ ฆ ง!
        string [NOT] MATCHES "่ กซฎญ" [ESCAPE "esc-char"]
         แฏฅๆแจฌขฎซ๋ ่ กซฎญ   D*E D?E D[EabHD]E D[^EdD-EzD]E  ฎงญ ็ ๎โ ฆ ง! จ ฉ

        expr rel-op {ALL | [ANY | SOME]} (SELECT-statement)
        expr [NOT] IN (SELECT-statement) !* Žก๋ชญฎขฅญญ๋ฉ *!
        [NOT] EXISTS  (SELECT-statement) !*  SQLฅขแชจฉ   *!

Dƒƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‚E
DƒŠAccess         GRANT/REVOKE, LOCK/UNLOCK,  SET LOCK MODE  ƒŠE
Dƒƒƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ„E
       {DBpriv         {PUBLIC  ฏเ ขฎ ค ข โ์ ฏเ ข 
DGRANTE   |            TO |       [WITH GRANT OPTION] [AS grantor]
     TBpriv ON table}   user-list}                 ฎโ ็ใฆฎฃฎ  จฌฅญจ

        {DBpriv            {PUBLIC
DREVOKEE   |             FROM |
      TBpriv ON table}     user-list}
                                             TABLE PRIVILEGES:
    DATABASE PRIVILEGES:                  ALTER           DELETE
                                          INDEX           INSERT
        CONNECT                               SELECT[(cols)]
        RESOURCE                              UPDATE [(cols)]
        DBA                                   ALL [PRIVILEGES]

DSET LOCK MODEE TO [NOT] WAIT     ฆค โ์ /ญฅ ฆค โ์ ฎแขฎกฎฆคฅญจ๏
DLOCK TABLEE table-name IN   {SHARE | EXCLUSIVE} MODE
DUNLOCK TABLEE table-name  {Œฎฆญฎ แฌฎโเฅโ์ | จ็ฅฃฎ ญฅซ์ง๏ }

Dƒƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‚E
DƒšIntegrity      Transaction, Audit trail                    ƒŠE
Dƒƒƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ„E
        เฎขฎคจโ์ โเ ญง ชๆจ๎ แ ญฎข๋ฌ LOG ไ ฉซฎฌ
DSTART  DATABASEE database  WITH LOG IN "/pathname" [MODE ANSI]

DDATABASEE database-name [EXCLUSIVE]
DROLLFORWARD DATABASEE database-name      ‚ฎแแโ ญฎขจโ์ ก งใ
DCLOSE DATABASEE                           จง backup-ชฎฏจจ

DBEGIN WORKE       ็ ซฎ โเ ญง ชๆจจ       ‚ญจฌ ญจฅ, ขแฅ จงฌฅญฅญญ๋ฅ
 . . .                                     แโเฎชจ ซฎชจเใ๎โแ๏!!
DCOMMIT WORKE     Koญฅๆ โเ ญง ชๆจจ
DROLLBACK WORKE   Žโช โจโ์ จงฌฅญฅญจ๏ ช ฏเฅค๋คใ้ฅฌใ COMMIT

DCREATE AUDITE FOR table-name IN "pathname"
   . . .
DRECOVER TABLEE table-name                ‚ฎแแโ ญฎขจโ์ โ กซจๆใ
DDROP   AUDITE FOR table-name

Dƒƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‚E
DƒŠAuxiliary      CHECK, REPAIR, INFO, OUTPUT, SET EXPLAINƒŠE
Dƒƒƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ‹ƒ„E
CHECK  TABLE table-name                 เฎขฅเจโ์ จญคฅชแ๋
REPAIR TABLE table-name                 ฅฌฎญโ จญคฅชแฎข
   เจฌฅ็ ญจฅ:  ฏฎค็ฅเชญใโ๋ฅ ฎฏฅเ โฎเ๋ ญฅซ์ง๏ จแฏฎซ์งฎข โ์ ข 4GL  
INFO {TABLES | COLUMNS FOR table-name
        | INDEXES FOR table-name | STATUS FOR table-name
        | {ACCESS | PRIVILEGES} FOR table-name}

DUPDATE STATISTICSE [FOR TABLE table-name]     แจแโฅฌญฎฌ ช โ ซฎฃฅ

DSET EXPLAINE {ON | OFF}          ‚ชซ๎็จโ์ แจแโฅฌญ๋ฅ ฎก`๏แญฅญจ๏

Last-modified: Thu, 12 Feb 1998 08:48:47 GMT
Žๆฅญจโฅ ํโฎโ โฅชแโ: