Skip to content

Commit 1147d2b

Browse files
committed
Restored what disappeared from branch 2.3
1 parent 713a1fa commit 1147d2b

File tree

5 files changed

+3464
-149
lines changed

5 files changed

+3464
-149
lines changed

doc/book/box/box_sql.rst

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,11 @@ Functions for SQL
77
The ``box`` module contains two functions related to SQL:
88

99
* ``box.schema.func.create`` -- for making Lua functions callable from
10-
SQL statements. This will be part of
11-
the documentation regarding SQL Plus Lua.
10+
SQL statements. See :ref:`Calling Lua routines from SQL <sql_calling_lua>`
11+
in the :ref:`SQL Plus Lua <sql_sql_plus_lua>` section.
1212

1313
* ``box.execute`` -- for making SQL statements callable from Lua functions.
14+
See the :ref:`SQL user guide <sql_sql_user_guide>`.
1415

1516
Some SQL statements are illustrated in the :ref:`SQL tutorial <sql_tutorial>`.
1617

@@ -20,7 +21,7 @@ Some SQL statements are illustrated in the :ref:`SQL tutorial <sql_tutorial>`.
2021

2122
Execute the SQL statement contained in the sql-statement parameter.
2223

23-
:param string sql-statement: statement, which should conform to the rules for SQL grammar
24+
:param string sql-statement: statement, which should conform to :ref:`the rules for SQL grammar <sql_sql_statements_and_clauses>`
2425
:param table extra-parameters: optional list for placeholders in the statement
2526

2627
:return: depends on statement
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
stack (
2+
line(
3+
choice(
4+
None,
5+
line(' CONSTRAINT ', 'name')
6+
)
7+
),
8+
line(
9+
choice(
10+
line(' PRIMARY ', ' KEY '),
11+
line(' NOT NULL '),
12+
line(' UNIQUE '),
13+
line(' DEFAULT ', 'expression'),
14+
line('foreign-key-clause')
15+
)
16+
)
17+
)
Lines changed: 110 additions & 0 deletions
Loading

0 commit comments

Comments
 (0)