Details
-
Task
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
None
Description
In addition to expressions, we'll allow DEFAULT as a dynamic SQL parameter:
EXECUTE IMMEDIATE examples
EXECUTE IMMEDIATE 'INSERT INTO t1 VALUES(?)' USING DEFAULT; |
EXECUTE IMMEDIATE 'UPDATE t1 SET a=?' USING DEFAULT; |
PREPARE..EXECUTE examples
PREPARE stmt FROM 'INSERT INTO t1 VALUES(?)'; |
EXECUTE stmt USING DEFAULT; |
PREPARE stmt FROM 'UPDATE t1 SET a=?'; |
EXECUTE stmt USING DEFAULT; |
This is for symmetry with the STMT_INDICATOR_DEFAULT indicator in the client-server bind protocol.
MDEV-11359 will also use this MDEV to add INGORE as another possible bind parameter, equal to STMT_INDICATOR_INGORE.
Attachments
Issue Links
- blocks
-
MDEV-11359 Implement IGNORE for bulk operation
-
- Closed
-
- relates to
-
MDEV-10709 Expressions as parameters to Dynamic SQL
-
- Closed
-
Activity
Field | Original Value | New Value |
---|---|---|
Description |
We'll allow {{DEFAULT}} as a dynamic SQL parameter:
{code:sql} EXECUTE IMMEDIATE 'INSERT INTO t1 VALUES(?)' USING DEFAULT; EXECUTE IMMEDIATE 'UPDATE t1 SET a=?' USING DEFAULT; {code} {code:sql} PREPARE stmt FROM 'INSERT INTO t1 VALUES(?)'; EXECUTE stmt USING DEFAULT; PREPARE stmt FROM 'UPDATE t1 SET a=?'; EXECUTE stmt USING DEFAULT; {code} This is for symmetry with the {{STMT_INDICATOR_DEFAULT}} indicator in the client-server bind protocol. |
We'll allow {{DEFAULT}} as a dynamic SQL parameter:
{code:sql} EXECUTE IMMEDIATE 'INSERT INTO t1 VALUES(?)' USING DEFAULT; EXECUTE IMMEDIATE 'UPDATE t1 SET a=?' USING DEFAULT; {code} {code:sql} PREPARE stmt FROM 'INSERT INTO t1 VALUES(?)'; EXECUTE stmt USING DEFAULT; PREPARE stmt FROM 'UPDATE t1 SET a=?'; EXECUTE stmt USING DEFAULT; {code} This is for symmetry with the {{STMT_INDICATOR_DEFAULT}} indicator in the client-server bind protocol. |
Link |
This issue blocks |
Link |
This issue relates to |
Description |
We'll allow {{DEFAULT}} as a dynamic SQL parameter:
{code:sql} EXECUTE IMMEDIATE 'INSERT INTO t1 VALUES(?)' USING DEFAULT; EXECUTE IMMEDIATE 'UPDATE t1 SET a=?' USING DEFAULT; {code} {code:sql} PREPARE stmt FROM 'INSERT INTO t1 VALUES(?)'; EXECUTE stmt USING DEFAULT; PREPARE stmt FROM 'UPDATE t1 SET a=?'; EXECUTE stmt USING DEFAULT; {code} This is for symmetry with the {{STMT_INDICATOR_DEFAULT}} indicator in the client-server bind protocol. |
In addition to expressions, we'll allow {{DEFAULT}} as a dynamic SQL parameter:
{code:sql} EXECUTE IMMEDIATE 'INSERT INTO t1 VALUES(?)' USING DEFAULT; EXECUTE IMMEDIATE 'UPDATE t1 SET a=?' USING DEFAULT; {code} {code:sql} PREPARE stmt FROM 'INSERT INTO t1 VALUES(?)'; EXECUTE stmt USING DEFAULT; PREPARE stmt FROM 'UPDATE t1 SET a=?'; EXECUTE stmt USING DEFAULT; {code} This is for symmetry with the {{STMT_INDICATOR_DEFAULT}} indicator in the client-server bind protocol. |
Summary | Dynamic SQL: 'INSERT INTO t1 VALUES(?)' USING DEFAULT | Dynamic SQL: DEFAULT as a bind parameter |
Description |
In addition to expressions, we'll allow {{DEFAULT}} as a dynamic SQL parameter:
{code:sql} EXECUTE IMMEDIATE 'INSERT INTO t1 VALUES(?)' USING DEFAULT; EXECUTE IMMEDIATE 'UPDATE t1 SET a=?' USING DEFAULT; {code} {code:sql} PREPARE stmt FROM 'INSERT INTO t1 VALUES(?)'; EXECUTE stmt USING DEFAULT; PREPARE stmt FROM 'UPDATE t1 SET a=?'; EXECUTE stmt USING DEFAULT; {code} This is for symmetry with the {{STMT_INDICATOR_DEFAULT}} indicator in the client-server bind protocol. |
In addition to expressions, we'll allow {{DEFAULT}} as a dynamic SQL parameter:
h2. EXECUTE IMMEDIATE examples {code:sql} EXECUTE IMMEDIATE 'INSERT INTO t1 VALUES(?)' USING DEFAULT; EXECUTE IMMEDIATE 'UPDATE t1 SET a=?' USING DEFAULT; {code} h3. PREPARE..EXECUTE examples {code:sql} PREPARE stmt FROM 'INSERT INTO t1 VALUES(?)'; EXECUTE stmt USING DEFAULT; PREPARE stmt FROM 'UPDATE t1 SET a=?'; EXECUTE stmt USING DEFAULT; {code} This is for symmetry with the {{STMT_INDICATOR_DEFAULT}} indicator in the client-server bind protocol. |
Description |
In addition to expressions, we'll allow {{DEFAULT}} as a dynamic SQL parameter:
h2. EXECUTE IMMEDIATE examples {code:sql} EXECUTE IMMEDIATE 'INSERT INTO t1 VALUES(?)' USING DEFAULT; EXECUTE IMMEDIATE 'UPDATE t1 SET a=?' USING DEFAULT; {code} h3. PREPARE..EXECUTE examples {code:sql} PREPARE stmt FROM 'INSERT INTO t1 VALUES(?)'; EXECUTE stmt USING DEFAULT; PREPARE stmt FROM 'UPDATE t1 SET a=?'; EXECUTE stmt USING DEFAULT; {code} This is for symmetry with the {{STMT_INDICATOR_DEFAULT}} indicator in the client-server bind protocol. |
In addition to expressions, we'll allow {{DEFAULT}} as a dynamic SQL parameter:
h3. EXECUTE IMMEDIATE examples {code:sql} EXECUTE IMMEDIATE 'INSERT INTO t1 VALUES(?)' USING DEFAULT; EXECUTE IMMEDIATE 'UPDATE t1 SET a=?' USING DEFAULT; {code} h3. PREPARE..EXECUTE examples {code:sql} PREPARE stmt FROM 'INSERT INTO t1 VALUES(?)'; EXECUTE stmt USING DEFAULT; PREPARE stmt FROM 'UPDATE t1 SET a=?'; EXECUTE stmt USING DEFAULT; {code} This is for symmetry with the {{STMT_INDICATOR_DEFAULT}} indicator in the client-server bind protocol. |
Status | Open [ 1 ] | In Progress [ 3 ] |
Assignee | Alexander Barkov [ bar ] | Oleksandr Byelkin [ sanja ] |
Status | In Progress [ 3 ] | In Review [ 10002 ] |
Status | In Review [ 10002 ] | Stalled [ 10000 ] |
Assignee | Oleksandr Byelkin [ sanja ] | Alexander Barkov [ bar ] |
issue.field.resolutiondate | 2016-11-27 14:22:27.0 | 2016-11-27 14:22:27.907 |
Fix Version/s | 10.2.3 [ 22115 ] | |
Fix Version/s | 10.2 [ 14601 ] | |
Resolution | Fixed [ 1 ] | |
Status | Stalled [ 10000 ] | Closed [ 6 ] |
Workflow | MariaDB v3 [ 78462 ] | MariaDB v4 [ 133013 ] |