ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ':
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
GET CURRENT;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
GET DIAGNOSTICS;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
GET CURRENT DIAGNOSTICS;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
# Statement information syntax
GET DIAGNOSTICS @var;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
GET DIAGNOSTICS var;
ERROR 42000: Undeclared variable: var
CREATE PROCEDURE p1()
BEGIN
GET DIAGNOSTICS var;
END|
ERROR 42000: Undeclared variable: var
CREATE PROCEDURE p1()
BEGIN
DECLARE var INT;
GET DIAGNOSTICS var;
END|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ';
END' at line 4
GET DIAGNOSTICS @var =;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
GET DIAGNOSTICS @var = INVALID;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'INVALID' at line 1
GET DIAGNOSTICS @var = MORE;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'MORE' at line 1
GET DIAGNOSTICS @var = CLASS_ORIGIN;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'CLASS_ORIGIN' at line 1
GET DIAGNOSTICS @var = INVALID,;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'INVALID,' at line 1
GET DIAGNOSTICS @var1 = NUMBER, @var2;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
GET DIAGNOSTICS @var1 = NUMBER, @var2 = INVALID;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'INVALID' at line 1
GET DIAGNOSTICS @@var1 = NUMBER;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '@var1 = NUMBER' at line 1
GET DIAGNOSTICS @var1 = NUMBER, @@var2 = NUMBER;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '@var2 = NUMBER' at line 1
CREATE PROCEDURE p1()
BEGIN
DECLARE var INT;
GET DIAGNOSTICS var = INVALID;
END|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'INVALID;
END' at line 4
CREATE PROCEDURE p1()
BEGIN
DECLARE var CONDITION FOR SQLSTATE '12345';
GET DIAGNOSTICS var = NUMBER;
END|
ERROR 42000: Undeclared variable: var
CREATE PROCEDURE p1()
BEGIN
DECLARE var INT;
GET DIAGNOSTICS var = NUMBER, var1 = ROW_COUNT;
END|
ERROR 42000: Undeclared variable: var1
GET DIAGNOSTICS @var = NUMBER;
GET DIAGNOSTICS @var = ROW_COUNT;
GET DIAGNOSTICS @var1 = NUMBER, @var2 = ROW_COUNT;
GET DIAGNOSTICS @var1 = ROW_COUNT, @var2 = NUMBER;
CREATE PROCEDURE p1()
BEGIN
DECLARE var INT;
DECLARE var1 INT;
DECLARE var2 INT;
GET DIAGNOSTICS var = NUMBER;
GET DIAGNOSTICS var = ROW_COUNT;
GET DIAGNOSTICS var1 = NUMBER, var2 = ROW_COUNT;
GET DIAGNOSTICS var1 = ROW_COUNT, var2 = NUMBER;
END|
DROP PROCEDURE p1;
# Condition information syntax
GET DIAGNOSTICS CONDITION;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
GET DIAGNOSTICS CONDITION 1 @var;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
GET DIAGNOSTICS CONDITION 1 var;
ERROR 42000: Undeclared variable: var
CREATE PROCEDURE p1()
BEGIN
GET DIAGNOSTICS CONDITION 1 var;
END|
ERROR 42000: Undeclared variable: var
CREATE PROCEDURE p1()
BEGIN
DECLARE var INT;
GET DIAGNOSTICS CONDITION 1 var;
END|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ';
END' at line 4
GET DIAGNOSTICS CONDITION 1 @var =;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
GET DIAGNOSTICS CONDITION 1 @var = INVALID;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'INVALID' at line 1
GET DIAGNOSTICS CONDITION 1 @var = NUMBER;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'NUMBER' at line 1
GET DIAGNOSTICS CONDITION 1 @var = INVALID,;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'INVALID,' at line 1
GET DIAGNOSTICS CONDITION 1 @var1 = CLASS_ORIGIN, @var2;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
GET DIAGNOSTICS CONDITION 1 @var1 = CLASS_ORIGIN, @var2 = INVALID;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'INVALID' at line 1
GET DIAGNOSTICS CONDITION 1 @@var1 = CLASS_ORIGIN;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '@var1 = CLASS_ORIGIN' at line 1
GET DIAGNOSTICS CONDITION 1 @var1 = CLASS_ORIGIN, @@var2 = CLASS_ORIGIN;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '@var2 = CLASS_ORIGIN' at line 1
CREATE PROCEDURE p1()
BEGIN
DECLARE var INT;
GET DIAGNOSTICS CONDITION 1 var = INVALID;
END|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'INVALID;
END' at line 4
CREATE PROCEDURE p1()
BEGIN
DECLARE var CONDITION FOR SQLSTATE '12345';
GET DIAGNOSTICS CONDITION 1 var = NUMBER;
END|
ERROR 42000: Undeclared variable: var
CREATE PROCEDURE p1()
BEGIN
DECLARE var INT;
GET DIAGNOSTICS CONDITION 1 var = CLASS_ORIGIN, var1 = SUBCLASS_ORIGIN;
END|
ERROR 42000: Undeclared variable: var1
GET DIAGNOSTICS CONDITION 1 @var = CLASS_ORIGIN;
GET DIAGNOSTICS CONDITION 1 @var = SUBCLASS_ORIGIN;
GET DIAGNOSTICS CONDITION 1 @var1 = CLASS_ORIGIN, @var2 = SUBCLASS_ORIGIN;
GET DIAGNOSTICS CONDITION 1 @var1 = SUBCLASS_ORIGIN, @var2 = CLASS_ORIGIN;
CREATE PROCEDURE p1()
BEGIN
DECLARE var INT;
DECLARE var1 INT;
DECLARE var2 INT;
GET DIAGNOSTICS CONDITION 1 var = CLASS_ORIGIN;
GET DIAGNOSTICS CONDITION 1 var = SUBCLASS_ORIGIN;
GET DIAGNOSTICS CONDITION 1 var1 = CLASS_ORIGIN, var2 = SUBCLASS_ORIGIN;
GET DIAGNOSTICS CONDITION 1 var1 = SUBCLASS_ORIGIN, var2 = CLASS_ORIGIN;
END|
DROP PROCEDURE p1;
# Condition number expression
GET DIAGNOSTICS CONDITION -1 @var = CLASS_ORIGIN;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '-1 @var = CLASS_ORIGIN' at line 1
GET DIAGNOSTICS CONDITION 1+1 @var = CLASS_ORIGIN;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '+1 @var = CLASS_ORIGIN' at line 1
GET DIAGNOSTICS CONDITION ? @var = CLASS_ORIGIN;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '? @var = CLASS_ORIGIN' at line 1
GET DIAGNOSTICS CONDITION (1) @var = CLASS_ORIGIN;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '(1) @var = CLASS_ORIGIN' at line 1
GET DIAGNOSTICS CONDITION p1() @var = CLASS_ORIGIN;