File: kdb_sql.txt

package info (click to toggle)
kdb 3.2.0-9
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 6,276 kB
  • sloc: cpp: 38,360; yacc: 940; python: 779; sh: 711; ansic: 440; lex: 367; xml: 182; sql: 51; makefile: 10
file content (35 lines) | stat: -rw-r--r-- 1,045 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
---------------------------------------------------------
 KDb Common SQL definition
 Copyright (C) 2003 Jarosław Staniek staniek at kde.org
 Started: 2003-09-10
---------------------------------------------------------

0. Preface
----------
Below is definition (formal grammar and comments) for SQL used externally by KDb.
"Externally" means that this language is visible to the user and can be used
by her/him to define queries.

Many attempts has been done to create common part of many SQL versions that
are currently in everyday use, mainly:
- SQLite
- MySQL
- PostgreSQL


1.1 CREATE TABLE
----------------

<CREATE_TABLE> ::= CREATE TABLE <table_name> (
                   <field_def>[,<field_def>]*
                   [,<table_constraint>]*
                   )
<field_def> ::= <field_name> <field_type> <field_constraint>

Note
----
CREATE TABLE statement could be added to KDbSQL for advanced users convenience,
although tables can be easier created with gui. CREATE TABLE for KDb has
non-standard KDb-specific options.

TODO.......