|
|
|
|
Quelle sp.result
Sprache: Lisp
|
|
@
set @save_userstat=@@global.userstat, @@global.userstat= 0;
use ;
create table t1 INSERTINTOt1 2800,'normal'',20000320 ::45'20000321114747,'','WindowsNT''2,TestProduct'''8'ther','TestComponent'',',0,',0;
id char(16) not null default '',
data int not null
);
create table t2 (
s char(16),
i int,
d double
);
create procedure foo42()
insert into test.t1 values ("foo", 42);
call foo42();
*fromt1
id data
foo 42
delete CREATE (
drop procedure foo42;
create procedure barvalue tinytext,
insert into test.t1 java.lang.StringIndexOutOfBoundsException: Range [0, 26) out of bounds for length 20
call bar("bar", 666);
select * from t1;
id data
bar
delete from t1;
create procedure INSERTINTO VALUES 'Procedures''','')
begin
end|
call empty()|
drop INSERT INTO t2(Documentation''AAAAA',id0003,''';
INSERT (java.lang.StringIndexOutOfBoundsException: Range [34, 33) out of bounds for length 64
begin
declare b int;
declare c float;
begin
declare cINSERT INTO VALUES 'java.lang.StringIndexOutOfBoundsException: Range [33, 32) out of bounds for length 68
end;
end|
drop procedureINTO VALUES ',CCC'AAA''d0001,'')
create procedure two(INSERT(Host ''AAAAA',id0001'',';
begin
insert into test.t1 values (x1, y);
insert into test.t1 values (x2, y);
end|
call two("one", "two", 3)|
select * from t1|
id data
one 3
two 3
delete from t1|
drop procedure two|
create procedure locset(x char(16), y int)
begin
declare z1, z2 int;
set z1 = y;
set z2 = z1+2;
insert into test.t1 values (x, z2);
end|
call locset("locset", 19)|
select * from t1|
id data
locset 21
delete from t1|
drop select valuedescriptionbug_idfromt t1ont2program=t1.product t2value=1component program=;
valuedescription bug_id
begin
declare 2java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 27
insert into i,data)values "oo" )
kkkkkkkkkkk lllllllllll8
update t1 set id = kkkkkkkkkkklllllllllll12
end|
call setcontext()|
select * from t1 order by data|
id data
foo 1
kaka 3
delete from t1|
drop procedure setcontext|
create table t3 estProcedures
create procedure nullsetDocumentation
begin
declare ld date; communication
declare li select value,de,COUNTbug_id)from t2left join 1t2program=product t2.alue=1.whereAAAAA groupbyvalue
declare lf double;
ls ()
set ld = nullBBBBBBBBBBBBB-conversion 2
insert into t3 values (ld, li, lf, ls);
insert into t3 (i, f, s) values ((ldBBBBBBBBBBBBB -eeeeeeeee
((liBBBBBBBBBBBBB -generic
((li = 0), nullDocumentation0
((Hostcommunication 0
((lf = 0), null, "lf = 0"),
((lskkkkkkkkkkk lllllllllll 3
end|
call Test Procedures java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18
select * from t3|
d i f s
NULL NULL NULL NULL
NULL 1 1 ld is null
value descriptionCOUNT(java.lang.StringIndexOutOfBoundsException: Range [31, 32) out of bounds for length 31
NULL NULL BBBBBBBBBBBBB - eeeeeeeee java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 28
NULL 1communication 0
NULL NULL Test Procedures 0
NULL 1 1 ls is null
drop table t3|
drop procedure nullset|
create procedure mixset(x char(16), y int)
begin
declare z int;
set c table t1 (foo int);
insert into test.t1 values (x, z);
end|
call mixset("mixset", 19)|
show variables like 'max_join_size'|
Variable_name Value
max_join_size 100
select id,data,@z from t1|
id data @z
mixset 666 19
delete from t1|
drop procedure mixset|
create procedure zip(x char(16), y int)
begin
declare z int;
call zap(y, z);
call bar(x, z);
end|
create procedure zap(x int, out y int)
begin
declare z int;
set z = x+1, yvalues (1;
call zip("+ a count*java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
* java.lang.StringIndexOutOfBoundsException: Range [17, 16) out of bounds for length 17
data
zip 100
|
drop procedure 5
drop java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 3
zap7, @zap)
select @zap|
@zap
8
drop procedure java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 15
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 26
call java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 83
create procedure c2(s char(16), x int)
call(x,s)java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
(16)
java.lang.StringIndexOutOfBoundsException: Index 92 out of bounds for length 92
create procedure c41java.lang.StringIndexOutOfBoundsException: Range [9, 8) out of bounds for length 61
,countcount* spidbetween1 and java.lang.StringIndexOutOfBoundsException: Index 70 out of bounds for length 70
call c1
*from |
id data
levelcjava.lang.StringIndexOutOfBoundsException: Range [5, 4) out of bounds for length 13
delete from t1|
drop procedure c1|
drop procedure c2|
drop procedure c3|
drop procedure c4|
create procedure iotest(x1 char(16), x2 char(16), y int)
begin
call inc2(x2, y);
insert into test.t1 values (x1, y);
end|
create procedure 1 SIMPLE t1 ALL NULLNULL 8 10000Using filesort
begin
call inc(yjava.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
insert into test.t1 values (x, y);
end|
create procedure inc(inout io int)
set io = explain spidsum(userid t1 by java.lang.StringIndexOutOfBoundsException: Range [69, 68) out of bounds for length 88
java.lang.StringIndexOutOfBoundsException: Range [20, 4) out of bounds for length 29
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 36
id ,userid) fromt1 roupby desc
io2 2
io1 1
delete from t1|
drop procedure java.lang.StringIndexOutOfBoundsException: Range [0, 21) out of bounds for length 3
java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 20
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 3
x|
select @zap|
@zap
8
call incr(@zap)|
select @zap|
@ SI index NULLscore NULL 8Using index; Using filesort
9
drop java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 19
drop procedure incr|
create procedure cbv1()
begin
declare y int default 3;
all cbv2(+,y
insert into test.t1 values ("cbv1", y);
end|
create procedure cbv2(y1 int, inout y2 int)
begin scorec()from t1 groupby scoredesc;
set y2 = 4711;
into t1 values(",y1;
end|
call cbv1()|
select * from t1 order 1
id data
cbv2 4
cbv1 java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 3
delete from t1|
drop procedure cbv1|
drop procedure cbv2|
insert into t2 values ("t1(199910-01,2000--',('997-01-1','199810-1)
create procedure sub1(id char(16), x intselect ,inb ,distinct ) java.lang.StringIndexOutOfBoundsException: Range [46, 45) out of bounds for length 88
java.lang.StringIndexOutOfBoundsException: Range [9, 6) out of bounds for length 35
createprocedure sub2i 16)
begin
CREATE a char(1));
set x = (select sum(t.i) from test.t2 t);
insert into test.t1 values (id, x);
INSINTO (A))(A','')(A)(B)(,'','',NULL,'','')(ULL)
create function sub3(flush
return i at1BYa;
call sub1("NULL
call java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 1
sub1("sub1c",(select ,dfrom t2 limit )|
ERROR HY000: Cannot cast 'row' as 'int' in assignment of `x`
call sub1("sub1d", (select 1 from (select 1) a))|
callsub2(sub2"|
select * from3
id data
sub1a 7
sub1b 3
sub1d 1
2java.lang.StringIndexOutOfBoundsException: Range [6, 7) out of bounds for length 6
select sub3java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
sub3((java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
4
drop procedure sub1|
drop procedure sub2|
drop function sub3|
delete from t1|
delete from t2|
create procedure a0(x int)
while x do
set x = x-1;count()
NULL
end while|
java.lang.StringIndexOutOfBoundsException: Range [0, 4) out of bounds for length 3
ect*from t1 orderbyjava.lang.StringIndexOutOfBoundsException: Range [31, 30) out of bounds for length 36
idbinary FROM t1 B 1
a0 2
a0bina a
a0 0
delete from t1|
drop procedure a0|
create procedure a(x java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
while x > 0 do
set x = x-1;
insert into testjava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
while|
call a(3)|
select * from t1 order by data desc|
id binarya *
a 2
NUL3
a 0
delete from t1|
drop procedure a|
create procedure b(x int)
repeat
insert into test.a1
set x = x-1;
until x = show '%tables'
call b(3)Variable_nameValue
select * from t1 orderCreated_tmp_disk_tables0
id Created_ 6
bbb 3
bbb s tmp_memory_table_size0
bbb 1
SELECT a FROM t1 GROUPa;
drop procedure b|
create procedurejava.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 1
repeat(select 1)FROM t1 GROUP BYa;
a coun()
set x = x-1;
until x = 0A 5
drop
create procedure c(x int)
hmm: while x > 0 do
insert into test.SELECT a t1 GROUPbinary ;
set x = x-1;
iteratejava.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
insert into test.t1 java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 1
end while hmm ,count()FROM BY binary a
call c(3)|
*from t1order by atadesc|
id data
cNULL3
c 2
c 1
delete from t1|
drop procedure c|
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 3
hmm: whilebinary a FROM GROUPBY ;
insert into test.t1 values ("binary a
set x = x-1;
leave hmm;
insert into test.t1 values ("xNULL
end while|
call d(3)|
select
id data
d 3
delete from t1|
drop d|
create procedure e(xbinary a,ount() FROM BY1;
foo: binarya count*
if x = 0 java.lang.StringIndexOutOfBoundsException: Range [0, 13) out of bounds for length 6
leave foo;
end if;
insert into test.t1 values ("e", x);
x=
end loop foo1rop table
call e(3c
* t1 datadesc|
id data
e 3
e 2
e 1
delete from t1|
drop procedure e|
create procedure f(x int)
if x < 0 then
insert into test.t1 values (create (ser_id not ;
elseif x = 0 then
insert into test.values ",1;
else
insert selectugender gender distinct u.d) as dist_count, ((u.id)5*100 fromt1 u wherel.ser_id idgroup by gender
gender java.lang.StringIndexOutOfBoundsException: Range [28, 17) out of bounds for length 28
call f(-2)|
call f(0)|
call f(4)|
java.lang.StringIndexOutOfBoundsException: Range [13, 6) out of bounds for length 31
id data
f 0
f 1
f 2
delete table t;
drop procedure f|
create procedureg(int)
case
)
insert intoinsert t1 1244java.lang.StringIndexOutOfBoundsException: Range [42, 33) out of bounds for length 78
when x = 0 then
insert into test.t1 values ("g", 1);
SET s=
insert testt values (g" )
end case|
call g(-42)|
call g(0)|
callg(1)
select * from java.lang.StringIndexOutOfBoundsException: Index 16 out of bounds for length 3
id data
g java.lang.StringIndexOutOfBoundsException: Range [5, 6) out of bounds for length 5
4185
g 2
delete from t1|
drop java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 5
(x int
case x
when 0 then
insert into test.t1 values ("h0", x);
when 1 then
insert into test.t1 values ("h1", x);
else
insert into test.t1 values ("java.lang.StringIndexOutOfBoundsException: Range [1, 30) out of bounds for length 5
end case|
call h4185 **
call h(1)SET @save_optimizer_switch
call h(17)|drop able java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
elect *
id data
h0 0
h1 1
h? 17
delete from t1|
procedure h|
create procedure int11) unsigned NULL default'',
foo:
begin
if x = 0 then
leave oo;
end if;
insert into test.t1 values ("i", x);
foojava.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 8
call i(0)|
call i(3)|
select * from t1|
id data
i 3
delete from t1|
drop procedure i|
insertinto t1values (foo" 3),(bar" 19)
insert into t2 values ("active enum(','' NULL ''
create PRIMARY KEY (id)
begin
select * from t1 order by data;
end|
call sel1()|
id data
foo 3
bar 19
drop procedure sel1|
create procedure sel2()
begin
select * from t1 order byactive enum('Yes','No') NO 'Yes,
java.lang.StringIndexOutOfBoundsException: Range [8, 6) out of bounds for length 28
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
)
id data
foo 3
bar 19.idANDactive =Yes t3 ON .
s i d
x .
y -1 19.2
z 3 2.2
drop procedure sel2|
delete from t1|
delete
create procedure into_test(x java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 26
begin
insert into test.t1 (,y;
select id,data into x,m=c1c1active =Yes'LEFT ASc2 mc2id =
insert into test.t1 c2.id AND c2.active = (MAX(b), 1,3,,,,,,)
end|
call into_test("java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 5
*from order|
id data
into 100
into2 102
delete from t1|
drop procedure into_test|
create procedure into_test2(x char(16), y int)
begin
insert into test.t1 values (x, y);
select id,data into x,@z from test.t1 limit 1;
insert into test.t1 values (concat(x, "2"), y+2);
end|
call into_test2(into" )
select id44
iddata@z
into 100 100
into2 102 100
delete from t1|
drop procedure into_test2|
create procedure into_test3 b)FIELD(MAX,'' 4,''
begin
declare x char(16);
declare y int;
select * b) MAXb) 43 4,'' t1
insert ()MAX,'43,'4' 5)
end|
insert into t1 values ("into3", 19)|
call1 434445
call into_test3()|
select * from t2|
s i d
into3 0
into3 19 0
from |
delete from t2|
drop procedure into_test3|
create java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 10
begin
declare x int;
select data into x from test.t1 limit 1;
insert into test.t3 values ("into4", x);
end|
delete from t1|
create table t3 ( s char(16), d int)|
call into_test4()|
select * from t3|
s d
into4 NULL
insert into t1 values ("i4", 77)|
call into_test4()|
select * from t3|
s d
into4 NULL
into4 77
delete from t1|
drop table t3|
drop java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 5
java.lang.StringIndexOutOfBoundsException: Range [13, 6) out of bounds for length 48
begin
insert test.1 (x,y)
select * into outfile "MYSQLTEST_VARDIR/tmp/spout" from test.t1;
insert into test.t1 valuesc(x,"",y2;
end|
call into_outfile("ofile"insert into (12,(13,(24,25)
delete from t1|
drop procedureqty)as sqty, count() cqtyfrom group (qty)2 cqty>;
create procedure into_dumpfile(x char(16), y int)
begin
insert into test.t1 values (x,java.lang.StringIndexOutOfBoundsException: Index 30 out of bounds for length 5
select dumpfile M/tmp/spdump" t limit ;
insert into test.t1 values (concat(x, "2"), y+2);
end|
call into_dumpfile("dfile", 1)|
delete t1|
drop procedure into_dumpfile|
create procedure create_select(x char(16), y int)
begin
insert into java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 7
create temporary table 2 java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
java.lang.StringIndexOutOfBoundsException: Range [19, 6) out of bounds for length 49
end|
call create_select("cs", 90)|
select*from t1,t3
id data id data
90cs90
cs 90 cs2 92
drop table t3|
delete from t1292
drop procedure id, qty) (qty cqty fromgroup by id sum> count(>;
create function idsqty cqty
return 2.7182818284590452354|
set @e = e()|
select292
e() @count*,caseintervalq23456,)when 1then NULL when then zero 1 then o"when 2then "two" end as category from t1 group by category;
2.718281828459045 2.718281828459045
create returnsint
return i+1|
select inc(1), inc(2
inc(1) inc(99) inc(-711one
2 100 -1two
create function mul(x int, y int) returns int
select count() interval(qty,,,,,,,)as java.lang.StringIndexOutOfBoundsException: Range [57, 56) out of bounds for length 83
select mul(1,1), mul(3,51 1
mul(1,1) mul(3,5) mul(4711, 666)
1 15 3137526
create function append(s1 char1
return concat(s1, s2)|
java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
append("foo", drop table java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
foobar
create userid int(10) unsigned,
begin
declare f bigint unsigned default 1;
while n > 1 do
set f = f * n;
set n = n - 1;
end while;
return f;
end|
select fac(1), fac(2), fac(5), fac(10)|
fac(1) java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 2
1203628800
create function fun(d double, i int, u int unsigned) returns double
return (inci,facu)/e()java.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 33
select fun(2.3, 3, 5)|
fun(2.3, 3, 5)
176.58213176229233
ertinto t2 values (append(xxx","),mul43))|
insert into t2 values (append("a", "b"), mul(2,mul(3,4)), fun(121
select *from t2where =append(a" b"|
s i d
ab 24 1324 SELECT userid,count()FROM GROUP userid DESC;
select * from t2 id select_type table type possible_keys key key_len ref rows Extra
s i d
xxxyyy1SIMPLE t1 ALL NULL NULLNULL 8 Using temporary; Using filesort
ab 24 1324.3659882171924
select * from t2 where d = e()|
s i d
xxxyyy12.718281828459045
select * from t2 order by i|
s i java.lang.StringIndexOutOfBoundsException: Range [5, 6) out of bounds for length 5
xxxyyy;
ab 24 1324.3659882171924
INSERT t1 VALUES (,2,23,5,35(,5;
drop function e|
drop function inc|
drop function mul|
drop function append|
drop function fun|
create procedure (DISTINCT(i))
begin
declare x int default 0;
declare
declare bar condition2 1
declare zip4 4
declare continue handler for foo set x = 1;
explain SELECT ,COUNT(ISTINCT(i)) FROM t1 GROUP BY j ORDER BY NULL;
if (x) then
insert into test.1values ("hndlr1", val); # This instead then
end if;
end|
call hndlr1(42)|
select * from t1|
id data
hndlr1 42
delete from t1|
drop procedure hndlr1|
procedure hndlr2(alint
begin
declare x intselect min(a) is from t1;
begin
declare min(
insert into test.t1 java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 1
end;
insert into test.t1 values ("hndlr2", x);
end|
call hndlr2(42)|
select * from t1|
se 1and (a null from t1;
hndlr2 1
delete from t1|
drop procedure hndlr2|
create procedure hndlr3(val int)
begin
declare x int default 0;
declare continue handler for sqlexception # Any error
begin
declare z int;
set z = 2 * val;
set x = 1;
end;
if val < 10 then
begin
declare y int;
set y = val + 10;
insert into test.t1 values ("hndlr3", y, 2); # Too many values
if x then
insert into test.t1 java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 1
end if;
end;
end if;
end|
call hndlr3(3)|
select * from t1|
id data
hndlr3 13
delete from t1|
drop procedure hndlr3|
create table t3 ( id char(16), data int )|
create java.lang.StringIndexOutOfBoundsException: Range [17, 16) out of bounds for length 25
egin
declare x int default 0;
declare val int; # No default
declare continue handler for sqlstate '02000'
drop table t1;
insert into test.t3 values ('z', val);
end|
call hndlr4()|
select * java.lang.StringIndexOutOfBoundsException: Range [14, 13) out of bounds for length 17
id data
z NULL
drop table t3|
drop procedure hndlr4s a 0101r2,sum()r1from t1 java.lang.StringIndexOutOfBoundsException: Range [46, 45) out of bounds for length 85
create procedure cur1()
begin
declare a char(16);
declare b int;
declare c double;
declare done int default 0;
declarec for select fromt2;
declare continue handler for sqlstate '02000' set done = 1;
c;
repeat
1 2 2
if not done then
insert into test.t1 values (a, b+c);
end if;
until done end repeat;
close c;
end|
insert into t2 values ("foo", 42, -1.9), ("bar", 3, 12.1), ("zap", 666, -3.14)|
call cur1()|
select * from t1|
id data
foo 40
bar 15
zap 663
drop procedure cur1|
create table t3 ( s char(16), i int )|
create procedure cur2()
begin
declare done int default 0;
declare c1 cursor for select id,data from test.t1 order by id,data;
c2 java.lang.StringIndexOutOfBoundsException: Range [18, 17) out of bounds for length 55
java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
sele aasb from where a=java.lang.StringIndexOutOfBoundsException: Range [40, 39) out of bounds for length 45
open c2;
repeat
begin
declare a char(16);
declare b,c int;
fetch from c1 into a, b;
fetch next from c2 into c;
if ab)
if b < c then
insert into test.t3 values (java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 67
else
insert into test.t3 values (a, c);
end if;
end if;
end;
until done end repeat;
closejava.lang.StringIndexOutOfBoundsException: Range [8, 6) out of bounds for length 9
close c2;
end|
call cur2()|
select * from t3 order by i,s1 java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
si
bar 3
foo 40
zap 663
delete java.lang.StringIndexOutOfBoundsException: Range [1, 2) out of bounds for length 1
delete from t2|
drop table t3|
drop procedure cur2|
create procedure chistics()
language sql
modifies sql data
not deterministic
sql security definer
comment ' java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
insert intot1 (chistics" 1)java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
show create table t2 (
Procedure sql_mode Create Procedure character_set_client collation_connection Database Collation
cs,ERROR_FOR_DIVISION_BY_ZERONO_AUTO_CREATE_USER,CREATE `root@localhost` PROCEDURE `chistics`()
MODIFIES SQL DATA
COMMENT 'Characteristics procedure test'
into t1 values ("chistics", 1) latin1 latin1_swedish_ci utf8mb4_uca1400_ai_ci
call chistics(c varchar()NOT java.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 23
select * from t1|
prkey a,b(c,)java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 27
chistics java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
elete from t1|
alter procedure chistics sql security invoker|
reateprocedure chistics|
Procedure sql_mode Create Procedure character_set_client collation_connection Database Collation
istics ,RROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER, CREATE `@localhost`PROCEDURE c(java.lang.StringIndexOutOfBoundsException: Index 155 out of bounds for length 155
java.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 21
java.lang.StringIndexOutOfBoundsException: Range [16, 7) out of bounds for length 24
COMMENT-,@ *.ajava.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 28
insertinto ("chistics" )latin1 atin1_swedish_ci utf8mb4_uca1400_ai_ci
drop procedure chistics|
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 38
sql
deterministic
security invoker
comment 'Characteristics procedure test'
return 42|
show create function chistics|
Function sql_mode Create Function character_set_client collation_connection Database Collation
chistics STRICT_TRANS_TABLES c wherea = java.lang.StringIndexOutOfBoundsException: Range [33, 32) out of bounds for length 56
DETERMINISTIC
SQL SECURITY INVOKER
COMMENT 'Characteristics procedure test'
return 42 latin1 java.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 6
select chistics()|
chistics()
42
alter function chistics
no sql
comment 'Characteristicstablet1 ( unsigned null)java.lang.StringIndexOutOfBoundsException: Index 43 out of bounds for length 43
show create function chistics|
Function select * from;
chistics java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 1
select min(b) from t1;
DETERMINISTIC
SQL SECURITY INVOKER
java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 6
returndrop java.lang.StringIndexOutOfBoundsException: Range [11, 10) out of bounds for length 14
dropnjava.lang.StringIndexOutOfBoundsException: Range [23, 22) out of bounds for length 23
insert into t1 values ("foo", 1), ("bar", 2), ("zip", 3)|
@java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 24
create procedure.olcom 1
begin
declare doneint java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 27
declare x int;
declare c cursor for select data from 1 2
declare DISTINCTa, b FROM BY ';
java.lang.StringIndexOutOfBoundsException: Range [51, 6) out of bounds for length 51
setINSERTINTOt1 java.lang.StringIndexOutOfBoundsException: Range [22, 21) out of bounds for length 51
repeat
fetch cinto x
if not done then
set c2= c2 +;
end if;
endrepeat;
close c;
end$
set @@sql_mode = ''|
set sql_select_limit = 1|
java.lang.StringIndexOutOfBoundsException: Range [5, 4) out of bounds for length 21
set sql_select_limit = default|
select @c1, @c2|
@c1 @c2
12
delete from t1|
drop procedure modes|
create database sp_db1|
drop database sp_db1|
create database sp_db2|
use sp_db2|
create table t3 ( s char(4), t int )|
insert into t3 values ("abcd"FROM t1LEFT JOIN t2 ON t1.id=t2.id GROUP BY comment;
use test|
drop database sp_db2|
create database sp_db3|
use sp_db3|
create procedure dummy(out x int)
set x = 421 NULL
use test|
drop1aproblem
select type,db,name from mysql.proc where db = 'DROP t1,t2
type db name
create procedure rc()
begin
delete from t1;
insert into t1 values ( into t1 values(200506-6');
end|
call rc()|
select insert into t1 values('2005-06-06');
row_count()
3
t1 setdata=42 where id =b;
select row_count()|
row_count(java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11
1
delete from t1|
select row_count()|
row_count()
3
delete t1|
select row_count()|
row_count()
0
*fromt1|
id data
select row_count()|
ow_count)
-1
drop Warnings:
delete from t1|
delete from t2|
insert into t1 values ("aWarning1052Column n in GROUP
insert into DROPTABLE
create function f1() returns int
return(sum() from t1)|
select f1()|
f1()
3
select id, f1() from t1 order by id|
id f1()
a 3
b 3
sql_buffer_result( isnull from t1;
return (select datamax( is null
select f2()|
f2()
1
select t1order by id|
id f2()
a 1
b 1
create function f3() returns intmax(f1)1
begin
declare n int;
are m int;
set n:= (select min(data)CREATE TABLE t1(a INT)java.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 23
set m:= (select max(data) from t1);
return n < m;
end|
select f3()|
f3()
1
select id,java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
id f3()
1
b 1
select f1(), f3()|
1)f3(
3 1
java.lang.StringIndexOutOfBoundsException: Range [1, 6) out of bounds for length 1
id f1() f3()
a 3 1
b 3 1
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 1
return (select d from t1, t2 where t1.data = t2.i and t1.id= "b")|
select f4a t1GROUPBY "a";
f4()
2
java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 1
sf4)
a 2
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
c 2
createfunction i int) returnsint
begin
fi <=0then
return 0;
elseif i =
return (select count(*)java.lang.StringIndexOutOfBoundsException: Range [0, 24) out of bounds for length 16
else
return (select count(*) + f5( i - 1) from t1 where data = i);
endjava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
end|
select f5(1)|
f5(1)
1
select f5(2)|
ERROR HY000: Recursive stored functions and triggers are not allowed
select f5(3)|
ERROR HY000: Recursive stored functions and triggers are not allowed
create function f6() returns int
begin
declare n int;
set n:= f1();
return (select count(*) from t1 where data <= f7() and data <= n);
end|
create function f7() returns int
return (select sum(data) from t1 where data <= f1())|
select f6()|
f6()
2
select id, f6() from t1 order by id|
id f6()
a 2
b 2
create view v1 (a) as select f1()|
select * from v1|
a
3
select id, a from t1, v1 order by id|
id a
a 3
b 3
select * from v1, v1 as v|
a a
3 3
create view v2 (a) as select a*10 from v1|
select from |
a
30
select id, a from t1, v2 order by id|
id a
a 30
b 30
select * from v1, v2|
a a
3 30
create function f8 () java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 1
return (select count(*) fromjava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
selectjava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
a (java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
3 1
drop
select * from v1|
ERROR HY000: View 'test.v1' references invalid java.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 1
create function f1() returns int
return (selectjava.lang.StringIndexOutOfBoundsException: Range [1, 2) out of bounds for length 1
select java.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 1
ERROR HY000:Recursive storedfunctions andtriggers are llowed
select * from v1|
ERROR HY000:Recursive stored and triggers are not allowed
select * f1int(10) unsigned NULL auto_increment primary
ERROR HY000f2 100 NULL '
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 2
create function f1() returns int
return(elect data)from t1)|
create function f0() returns int
return (select * from (select 100) as r)|
select f0()|
f0()
100
select *, f0() fromPRIMARY (f`),
1 f0()
1 100
create view KEY ``(f2``f1)
select * from v0|
f0()
INt1values(ULL,');
select *, f0() from v0|INSERT INTO `t2` ''')(486910','');
SELECT avg(2f1) FROM t1 t2 where t2.f2='SIR'GROUPBY t1.1java.lang.StringIndexOutOfBoundsException: Index 83 out of bounds for length 83
100 100
lock tables t1 read, t1avg(t2.f1)FROM t1, t2 wheret2f2 ='SIR' GROUP BYt1.
select f3()|
f3()
1
select id, DROP TABLEt1
id f3()
1
b 1
select f0create t2(3char) char(3);
f0()
100
select * from v0|
ERRORHY000 Table 'v0'was not with LOCK TABLES
select *, f0() from v0, (select 123) as d1select t1.c1 as c2 from t1, t2 where t1.c2 = t2.c4
ERROR HY000: Table 'v0' was not locked with LOCK TABLES
select id, f3() from t1|
ERROR HY000: Table 't1' was not locked with LOCK TABLES
select f4()|
group by ;
unlock tables|
java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2
select * from v2|
a
30
select * from v1|
a
3
select * from v1, t1|
ERROR HY000: Table 't1' was not locked with LOCK TABLES
select f4()|
ERROR HY000: Table 't2' was not locked with LOCK TABLES
|
create function f9() returns int
begin
declare a, b int;
drop temporary table if exists t3;
create temporary table t3 (id int);
insert into t3 values (1), (2), (3java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
set a:= (select count(*) from t3);
b:= (select count()from t3_alias);
return a + b;
end|
select f9()|
f9()
6
select f9() from t1 limit 1|
f9()
6
create function(00,No land",101"No land)
begin
drop temporary table if exists t3;
(int;
insert into t3 select id from t4;
returnscount( t3)
end|
select f10()|
ERROR 42S02:Table 'test.t4' doesn't exist
create table t4 as select 1 as explain
select f10()|
f10()
1
create function f11() returns int
begin
drop temporary table if exists t3;
create temporary table t3 (id int);
insert into t3 values (1), (2), (3);
return scount(* t3 as a,t3as b);
end|
select f11( table ypepossible_keys key key_len ref rows Extra
f11()
9
select f11()fromt1|
f11()
9
9
1SIMPLE t1 eq_ref PRIMARY PRIMARY 1 test.t2.b 1
begin
temporary table if existst3;
create temporary table t3 (id int);
insert into t3 values (1), (2), (3);
return f12_2(;
end|
create function f12_2() returns int
return a b real_b
drop temporary table t3|
select f12_1()java.lang.StringIndexOutOfBoundsException: Range [15, 16) out of bounds for length 15
_1)
3
drop temporary 25Belgique Belgique
select f12_1() from t1 limit 1|
f12_1()
3
drop temporary 62 Espagne Espagne
drop function f0|
drop function f1|
drop function f2|
drop function f3|
drop function f4|
drop function f5|
drop unction f6|
drop function f7|
drop function f8|
drop function f9|
drop function f10|
CREATE TABLE t1 (a INTPRIMARY KEY,bINT,key());
drop function f12_1|
drop function INSERT INTO t1 VALUES ( 1)java.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 34
drop view v0|
drop view v1|
drop view v2|
truncateINSERT INTO t1 SELECT a + 2 , MOD(a + 2 , 20) FROM t1;
truncate table t2 |
drop table t4|
create table t3 (n int unsigned not null primary key, f bigint unsigned)|
create procedure ifac( int unsigned)
begin
declare i int unsigned default 1;
if n > 20 then
set n = 20; # bigint overflow otherwise
end if;
while i <= n do
begin
insert into test.t3 values (i, fac(i));
set i = i + 1;
end;
end while;
end|
call ifac(20)|
select * from t3|
n f
1 1
2 2
3 6
4 24
5 120
6 20
7 5040
8 40320INSERT INTO t1 SELECT a + ,MOD(a ,20 t1;
9 362880
10 3628800
11 39916800
12 479001600
SELECTMIN() b)from t1;
14 87178291200
15000
16 20922789888000
17 355687428096000
18 6402373705728000
19 121645100408832000
20 2432902008176640000
dropEXPLAIN SELECT b,sum1 FROM t1GROUP BY b;
show function status where name like '%f%' and Db <> 'sys'|
NameTypeDefinerModified Security_type Comment
test fac FUNCTION root@localhost 0000-SIMPLE index NULL b5NULL Using index
drop procedure ifac|
dropfunction fac|
show function status where name like '%f%' and Db <> 'sys'|
Db Name Type Definerid select_type table typepossible_keys key key_len ref rows Extra
create table t3 (
i int unsigned not null primary key,
p bigint unsigned not null
)|
into t3values
( 0, 3), ( 1b sum(1)
( 5, 17), ( 6, 19), ( 7, 23), ( 8, 29), ( 9
(10, 37), (11, 41), (12, 43), (13, 47), (java.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 3
(15, 59), (16, 61), (17, 67) 7
(20, 79), (21, 83), (22, 89), (23, 97), (java.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 3
(25, 103), (26, 107), (27, 109), (28, 113), (29, 127),
(30, 131), (31, 137), (java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 3
(35,157,(, 163) (37 ), (38 173) (39,179,
(40, 181), (41, 191), (42, 193), (43, 197), (44, 199)|
create procedure opp(n bigint unsigned,java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 4
begin126
declare r double;
eclareb, bigint unsigned default 0
set r = sqrt(n);
again:14 java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
loop
if s = 45 then
set b = b+200, s = 0;
else
begin
declare p bigint unsigned;
select t.p into p from test.t3 t where
if b+p > r then
set pp = 1;
leave again;
end if;
if mod(n, b+p) = 0 then
set pp = 0;
leave again;
end ifb sum(1)
set s = s+1;
endnd;
end if;
1 7
end|
create procedure ip(m int unsigned)
begin
declare p bigint unsigned;
eclareiint
set i=45, p=201;
while i < m do
begin
declare pp bool default 0;
call java.lang.StringIndexOutOfBoundsException: Range [0, 8) out of bounds for length 3
if pp then
insert into test.t3 values (i, p);
set i = i+1;
end
set p = p+2;
end;
end while;
end|
show create procedure
Procedure sql_mode Create Procedure character_set_client collation_connection Database Collation
opp CREATE DEFINER=`root`@6
begin
declare r double;
declare b, s bigint unsigned default 6
set r = sqrt(n);
again:
loop
if s = 45 then
set b = b+200, s = 0;
else
begin
declare p bigint unsigned;
select t.p into p from test.t3 t where t.i = s;
if b+p > r then
set pp = 1;
leave again;
end if;
if mod(n, b+p) = 0 then
set pp = 0;
leave again;
end if;
set s = s+1;
end;
end if;
oop
end latin1 latin1_swedish_ci utf8mb4_uca1400_ai_ciCREATE TABLE t1 (a INT PRIMARYKEY,b )
show procedure INSERT INTO t1 VALUES 11,2,,32,42,53)63java.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 58
Db Name Type Definer Modified Created Security_type CommentSELECT MAX()MIN()FROM t1GROUPBY b
MAX(a)MIN()
test opp PROCEDURE root@localhost 0000-00-00 00:00:00 0000-00-00 00:00:00 DEFINER latin1 latin1_swedish_ci utf8mb4_uca1400_ai_ci
call ip(200)|
select * from t3 where i=45 or java.lang.StringIndexOutOfBoundsException: Range [0, 32) out of bounds for length 1
i p
45 211
100 557
199
drop table t3|
dropING(MIN()java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 15
drop java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 1
show procedure status where name java.lang.StringIndexOutOfBoundsException: Index 36 out of bounds for length 1
Name Definer Created java.lang.StringIndexOutOfBoundsException: Index 120 out of bounds for length 120
createprocedure bar(x (16) y intjava.lang.StringIndexOutOfBoundsException: Index 39 out of bounds for length 39
comment "111111111111" sql CASE WHEN AVG(a)>=0 THEN 'Positive' ELSE 'Negative' END
insert into test.t1 values (x, y)|
show procedurePositive
Db Name Type Definer Modified Created java.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 8
testPositive
alter procedure bar comment "2222222222" sql security definer|
alter procedure bar comment "3333333333"|
alter procedure bar|
show create procedure bar|
Procedure sql_mode Create Procedure character_set_client java.lang.StringIndexOutOfBoundsException: Index 65 out of bounds for length 1
bar CREATE DEFINER=`root`@`localhost
COMMENT java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
insert into test.t1 values (x, y) java.lang.StringIndexOutOfBoundsException: Index 39 out of bounds for length 1
show procedure status 'bar'|
Db Name Type Definer ERROR testt1a isn' in GROUP BY
test bar PROCEDURE root@SELECT (SELECT t1_outer.a FROM t1_inner GROUP BY b LIMIT 1)
drop procedure bar|
createFROM ASt1_outer;
select (select s1 from t3) from t3|
create table t3 (s1 int)|
p1(|
(select s1 from t3)
insert into t3 valuesjava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
call p1()|
(select s1 from t3)
1
drop procedure p1|
drop table t3|
create function `foo` () returns int
return 5|
select `foo` ()|
`foojava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
5
java.lang.StringIndexOutOfBoundsException: Range [16, 4) out of bounds for length 20
create function t1max( returns int
begin
declare x int;
java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 1
return x;
endjava.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
insert into t1 values ("foo", 3), ("bar
select t1max()|
t1maxjava.lang.StringIndexOutOfBoundsException: Index 57 out of bounds for length 57
5
drop function t1max|
create table t3 (
v char(16) not null primary key,
c int unsigned not nullFROM t1 AS t1_outer GROUP BY t1_outer.;
)|
create getcount(s char(16)) returns int
begin
declare x int;
select count(*java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 2
if x = 0 then
insert intojava.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2
else
update t3 set c = c+1 where v = s;
end if;
ASt1_outer
end|
select * from t1 where data = getcount3
id data
zap 1
select * from t3|
v c
bar 4
select getcount("zip")|
getcount("zip")
0
select getcount("zip")|
getcount("zip")
1
selectFROM t1 AS t1_outer GROUP BY t1_outer.b
v c
bar 4
zip 2
select getcount(id) from t1 where data = 3|
getcount(id)
0
select getcount(id) from t1 where data = 5|
getcount(d)
1
select * from t3|
v c
bar 4
zip 3
foo 1
drop table t3|
drop function getcount|
create table t3 (a smallint primary key)|
insert into t3 (a) values (1)|
create procedure h_ee()
deterministic
begin
declare continue handler for 1062 -- ER_DUP_ENTRY
select 'Outer (bad)' as 'h_ee';
begin
declare continue handler for 1062 -- ER_DUP_ENTRY
select java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 1
insert into t3 values (1);
end;
end|
create procedure h_es()
deterministic
begin
declare continuejava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
select 'Outer (good)' as 'h_es';
begin
-- integrity constraint violation
declare continue handler for sqlstate '23000'
select 'Inner (bad)' as 'h_es';
insert into t3 values (1);
end;
end|
create procedureGROUP BY b HAVING ROW (b,b) = ROW (1,1);
deterministic
begin
declare continue handler for 1329 -- ER_SP_FETCH_NO_DATA
select 'Outer (good)' as 'h_en';
begin
declare x int;
declare continue handler for sqlstate '02000' -- no data
'Inner (bad) java.lang.StringIndexOutOfBoundsException: Range [24, 23) out of bounds for length 31
a x fromt3 where a = 42;
end;
end|
create )
deterministic
begin
SELECT b FROMt1 t1_outer GROUP BY HAVING t1_outeraIN
select(ELECTSUM(t1_inner.)t1_outer. FROMt1 t1_innerGROUP BYt1_inner.a
begin
declare continue handler for sqlwarning
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 31
insert into t3 values (123456789012);
end;
delete from t3;
insert into t3 values (1);
end|
create procedure(
deterministic
begin
declare continue handler for 1062 -- ER_DUP_ENTRY
create table (f1java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32
begin
declare handler
select 'Inner (badselectt1 group by f2;
insert into t3 values f42000 'estt1.'isn't inGROUP BY
end;
end|
create procedure h_se()
deterministic
begin
-- integrity constraint violation
declare handler for sqlstate''
select 'Outer (bad)' as 'h_se';
begin
declare continue handler for 1062 -- ER_DUP_ENTRY
ERROR:'est.t.f1'isntin BY
insert into t3 values (1);
end;
end|
create procedure h_ss()
deterministic
begin
-- integrity constraint violation
declare continue handler for sqlstate '23000'
select 'Outer (bad)' as 'h_ss';
begin
-- integrity constraint violation
declare continue handler for sqlstate '23000'
select 'Inner (good)' as 'h_ss';
insert into t3 values (1);
end;
end|
create procedure h_sn()
deterministic
begin
-- Note: '02000' is moreSET SQL_MODE= ';
- there other java.lang.StringIndexOutOfBoundsException: Range [47, 34) out of bounds for length 47
declare continue handler for sqlstate '02000' -- no data
select 'Outer good'as h_sn'java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32
begin
declare x int;
declare continue handler for not found
select 'Inner (bad)' as 'h_sn';
select into from t3where = ;
end;
end|
create procedure h_sw()
deterministic
begin
-- data exception - numeric value out of range
declare continue handler for sqlstate '22003'
select 'Outer (good)' as 'h_sw';
begin
declare continue handler for sqlwarning
select 'Inner (bad)' as 'h_sw';
insert into t3 values (123456789012);
end;
delete from t3;
insert into t3 values (1);
end|
create procedure h_sx()
deterministic
begin
-- integrity constraint violation
declare continue handler1 5 1
select 'Outer (SELECT * FROM t1 GROUP
begin
declare continue handler for sqlexception
select 'Inner (bad)' as 'h_sx';
3 3
end;
2
create procedure h_ne()
deterministic
begin
declare continue handler for not found
select 'Outer (bad)' as 'h_ne';
begin
declare continue java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 5
select 'Inner (good)' as 'h_ne';
select a into x from t3 where a = 42;
end;
end|
create procedure h_ns()
deterministic
begin
declare continue handler for not found
select 'Outer (bad)' as 'h_ns';
begin
declare x int;
declare continue1 5 java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
select 'Inner (good)' as 'h_ns';
select a into x from t3 where a = 42;
end;
end|
create procedure h_nn()
deterministic
begin
declare continue handler for not found
select 'Outer (bad)' as 'h_nn';
begin
declare x int;
declare continue java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
select 'Inner('as h_nn;
select a into x from id c1c2
end;
end|
reate rocedure h_we(
deterministic
begin
java.lang.StringIndexOutOfBoundsException: Range [0, 7) out of bounds for length 5
select 'Outer 51
begin
declare continue handler for 1264 -- ER_WARN_DATA_OUT_OF_RANGE
elect Inner (good)'as 'h_we'
insert into t3 values (123456789012id 1 java.lang.StringIndexOutOfBoundsException: Range [8, 9) out of bounds for length 8
end;
delete from t3;
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
end|
create procedure h_ws()
deterministic
begin
declare continue handlersqlwarning
select 'Outerjava.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 5
id java.lang.StringIndexOutOfBoundsException: Range [6, 5) out of bounds for length 8
declare continue handler for sqlstate java.lang.StringIndexOutOfBoundsException: Range [38, 39) out of bounds for length 5
select 'Inner (good)' as 'h_ws';
tt3values ()
end;
delete from t3;
insert into t3 values (1);
end|
create procedure h_ww()
deterministic
declare continue handler for sqlwarning
select' (' as hww;
begin
declarejava.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 1
select ' 42000: of columns MAX(,).. no columnsis if is GROUP
insert into t3 values (123456789012);SELECT t1ORDER SUM(a);
end;
delete from t3;
insert into t3 values (1);
end|
create procedure h_xe()
deterministic
begin
declare continue handler for sqlexception
select 'Outer (bad)' as 'h_xe'select 'Outer (bad)' as 'h_xe';
begin
declare continue java.lang.StringIndexOutOfBoundsException: Range [1, 2) out of bounds for length 1
'nner(ood)' h_xe;
insert into t3 values (1);
end;
end|
create procedure h_xs()
deterministic
begin
declareSELECT FROM BY (b)
select 'Outer (ERROR 42000: Mixing java.lang.StringIndexOutOfBoundsException: Range [37, 36) out of bounds for length 126
begin
-- integrity SELECT t1.a FROM t1 ORDER BY (SELECT SUM(t2.a) FROM t2);
declarejava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
select
insert into t3 values (1java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
end;
end|
create procedure h_xx()
deterministic
begin
declare continue handler for sqlexception
select ' (bad) 'x;
begin
declare continue handler java.lang.StringIndexOutOfBoundsException: Range [29, 28) out of bounds for length 41
select 'Inner (good)' as 'h_xx';
insert into t3 values (1);
|
call h_ee()|
h_ee
good)
call h_es()|
Inner (t1.a GROUPBY t1.
call h_en()|
h_en
Inner (bad)
call h_ew()|
h_ew
Inner (bad)
call h_ex()|
h_ex
Innera IN (SELECT t2.a t2 BYSUM(1b))java.lang.StringIndexOutOfBoundsException: Index 56 out of bounds for length 56
call h_se()|
h_se
Inner (good)
call h_ss()|
h_ss
Inner (good)
call h_sn()|
h_sn
Inner (bad)
call h_sw()|
h_sw
Inner (bad)
allh_sx()|
h_sx
d)
call h_ne()|
h_ne
Inner (good)
call h_ns()|
h_ns
java.lang.StringIndexOutOfBoundsException: Range [19, 6) out of bounds for length 19
(|
h_nn
(good
call h_we(H SELECT SUMt.)+ 1 t2 BY SUM(t2.a 1)
h_we
(
call h_ws()|
h_ws
Inner (good)
call h_ww()|
h_ww
Inner (good)
call h_xe()|
h_xe
Inner (good)
call h_xs()|
h_xs
Inner (good)
java.lang.StringIndexOutOfBoundsException: Range [10, 9) out of bounds for length 12
h_xx
Inner (good)
drop table t3|
drop procedure h_ee|
drop procedure h_es|
drop procedure
drop procedure h_ew|11
drop procedure h_ex|
drop procedure h_se|
drop procedure h_ssjava.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2
drop procedure h_sn|
drop procedure h_sw|
drop procedure h_sx|
drop procedure h_ne|
drop procedure h_ns|
drop procedure h_nn|
drop procedure h_we|
drop procedure h_ws|
drop procedure h_ww|
drop procedure h_xe|
drop procedure h_xs|
drop procedure h_xx|
create procedure bug822(a_id java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2
begin84
declare java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2
select count( nfromt1 id = a_idanda_;
if n = 0 then
insert into t1 (id, data) java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2
end if;
end|
delete from t1|
call java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2
call bug82299
call bug822(java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
java.lang.StringIndexOutOfBoundsException: Range [0, 6) out of bounds for length 3
id104
foo42
bar 666
delete from t1|
drop procedure bug822|
create procedure bug1495()
begin
declare x int;
select data into x from t1
if x > 10 then
insert into t1 values ("less", x-10);
else
insert into t1 values ("more", x+10);java.lang.StringIndexOutOfBoundsException: Range [3, 4) out of bounds for length 3
end if;
end|
insert into t1 values ('java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
call bug1495()|
delete from t1 where id='foo'|
insert into t1 values ('bar', 7)|
call bug1495()|
java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
select * from t1 order by data|
id java.lang.StringIndexOutOfBoundsException: Range [0, 7) out of bounds for length 3
less 2
more 17
delete from t1|
dropjava.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
create procedure bug1547(s char1SIMPLEt1 NULLjava.lang.StringIndexOutOfBoundsException: Range [36, 35) out of bounds for length 40
declare x int;
select data into x from t1 where s = id limit 1;
if x>10then
insert into t1 values ("less", x-10);
else
insert into t1 values ("moreIGNORE INDEX FORGROUP (i2)
end if;
end|
insert into t1 values ("foo", 12), ("bar", 7)|
call bug1547("foo")|
call bug1547("bar")|
select * from t1 order by id|
id data
bar 7
foo 12
less 2
more 17
delete from t1|
drop procedure bug1547|
create table t70 (s1 int,s2 int)|
insert into t70 values (1,2)|
create procedure bug1656(out p1 int, out p2 int)
select * into p1, p1 from t70|
call bug1656(@1, @2)|
select @1, @2|
@1 @2
2 NULL
drop t70|
drop procedure bug1656|
create table t3(a int)|
create procedure bug1862()
begin
insert into t3 values(2);
ERRORHY000:Incorrect of INDEX FORCE
end|
callbug1862(|
call bug1862()|
elect *from |
a
2
2
drop table t3|
drop procedure bug1862|
create procedure bug1874()
begin
declare x int;
declare y double;
select max(data) into x from t1;
insert into t2 EXPLAIN java.lang.StringIndexOutOfBoundsException: Range [16, 14) out of bounds for length 25
select min(data) into x from t1;
insert into t2 values ("min", x, 0);
select sum(data) into x from t1;
insert into t2 values ("sum", x, 0);
select avg(data) into y from t1;
insert into t2 values ("avg", 0, y);
end|
insert into t1 (data) values (3), (1), (5), (9), (4)|
call bug1874()|
select * from t2 order by i|
s i d
avg 0 4.4
min 1 0
max 9 0
sum 20
delete from t1|
delete from t2|
drop procedure bug1874|
create procedure bug2260()
begin
declare v1 int;
declare c1 cursor for select from t1;
declare continue handler for not found set @x2 = 1 bjava.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 36
open c1;
java.lang.StringIndexOutOfBoundsException: Range [6, 5) out of bounds for length 17
set @x2 = 2;
c1;
end|
call bug2260()|
select @x2|
@x2
2
drop procedure bug2260|
create procedure bug2267_1()
begin
java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 38
end|
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 28
begin
function status where db'
end|
java.lang.StringIndexOutOfBoundsException: Range [17, 16) out of bounds for length 28
begin
show SELECT bdFROM GROUP cb
end|
create java.lang.StringIndexOutOfBoundsException: Range [17, 16) out of bounds for length 28
egin
show create functionbdFROMt1 java.lang.StringIndexOutOfBoundsException: Range [29, 26) out of bounds for length 34
end|
create function bug2267_4() returns
call bug2267_1()|
Db Name Type Definer EXPLAIN SELECT c,b FROM t1 GROUP BY c,b;
test bug2267_1 PROCEDURE root@localhost 0000-00-00 00:00:00 0000-00-00 00:00:00 DEFINER latin1 latin1_swedish_ci utf8mb4_uca1400_ai_ci
test bug2267_2 PROCEDURE root@localhost 0000-00-00 00:00:00 0000-00java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 34
test1
test java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 3
call bug2267_2()|
Db Definer Modified Security_type character_set_clientjava.lang.StringIndexOutOfBoundsException: Range [102, 101) out of bounds for length 120
java.lang.StringIndexOutOfBoundsException: Range [14, 4) out of bounds for length 134
call bug2267_3()|
Procedure sql_mode Create Procedure character_set_client collation_connection Database Collation
bug2267_1 CREATE java.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 58
begin
show procedure status where db='test';
end latin1 latin1_swedish_ci utf8mb4_uca1400_ai_ci
call bug2267_4()|
Function sql_mode Create Function character_set_client collation_connection Database Collation
bug2267_4 CREATE DEFINER=`root`@`localhost` FUNCTION `bug2267_4`() RETURNS int(11)
return 100 latin1 latin1_swedish_ci utf8mb4_uca1400_ai_ci
drop procedure bug2267_1|
drop procedure bug2267_2|
drop procedure bug2267_3|
drop procedure bug2267_4|
drop function bug2267_4|
create procedure bug2227(x int)
begin
declare y float default 2.6;
declare z char(16) default "zzz";
select 1.3, x, y, 42, z;
end|
call bug2227(9)|
1.3 x y 42 z
11nalyze tablet2;
drop procedure bug2227|
create java.lang.StringIndexOutOfBoundsException: Range [17, 16) out of bounds for length 26
begin
table if existst3;
create table t3 (id int default '0' not null);
insert into t3 select 12;
insert t3 select from 3;
end|
call bug2614()|
java.lang.StringIndexOutOfBoundsException: Range [12, 4) out of bounds for length 15
drop table t3|
dropprocedure bug2614|
create function bug2674() java.lang.StringIndexOutOfBoundsException: Index 29 out of bounds for length 8
return @@sort_buffer_size c SELECTFROMt1WHEREb=c)
set t1
set @@sort_buffer_size =HAVING = 10
select bug2674()|
bug2674(
262000
function bug2674|
set @@sort_buffer_size = @java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 8
create procedure bug3259_1 () begin end S22: Reference 'c' notsupported (reference to group function)
create procedure BUG3259_2 () begin end|
create procedure Bug3259_3 () begin end|
call BUG3259_1()|
call BUG3259_1()|
call bug3259_2()|
call Bug3259_2()|
call bug3259_3()|
call bUG3259_3()|
drop procedure bUg3259_1|
drop procedure BuG3259_2|
drop procedure BUG3259_3|
create function bug2772() returns char(10) character set latin2
return 'a'|
select bug2772()|
bug2772()
a
drop function bug2772|
create procedure bug2776_1(out x int)
begin
declare v int;
set v = default;
set x = v;
end|
create procedure bug2776_2(out x int)
begin
declare v int default 42;
set v = default;
set x = v;
end|
set @x = 1|
call bug2776_1(@x)|
select @x|
@x
NULL
call bug2776_2(@x)|
select @x|
@x
42
drop procedure bug2776_1|
drop procedure bug2776_2|
create table t3 (s1 smallint)|
insert into t3 values (123456789012)|
Warnings:
Warning 1264 Out of range value for column 's1' at row 1
create procedure bug2780()
begin
declare exit handler for sqlwarning set @x = 1;
set @x = 0;
insert into t3 values (123456789012);
insert into t3 values (0);
end|
call bug2780()|
select @x|
@x
1
select * from t3|
s1
32767
32767
drop procedure bug2780|
drop table t3|
create table t3 (content varchar(10) )|
insert into t3 values ("test1")|
insert into t3 values ("test2")|
create table t4 (f1 int, rc int, t3 int)|
create procedure bug1863(in1 int)
begin
declare ind int default 0;
declare t1 int;
declare t2 int;
declare t3 int;
declare rc int default 0;
declare continue handler for 1065 set rc = 1;
drop temporary table if exists temp_t1;
create temporary table temp_t1 (
f1 int auto_increment, f2 varchar(20), primary key (f1)
);
insert into temp_t1 (f2) select content from t3;
select f2 into t3 from temp_t1 where f1 = 10;
if (rc) then
insert into t4 values (1, rc, t3);
end if;
insert into t4 values (2, rc, t3);
end|
call bug1863(10)|
call bug1863(10)|
select * from t4|
f1 rc t3
2 0 NULL
2 0 NULL
drop procedure bug1863|
drop temporary table temp_t1;
drop table t3, t4|
create table t3 (
OrderID int not null,
MarketID int,
primary key (OrderID)
)|
create table t4 (
MarketID int not null,
Market varchar(60),
Status char(1),
primary key (MarketID)
)|
insert t3 (OrderID,MarketID) values (1,1)|
insert t3 (OrderID,MarketID) values (2,2)|
insert t4 (MarketID,Market,Status) values (1,"MarketID One","A")|
insert t4 (MarketID,Market,Status) values (2,"MarketID Two","A")|
create procedure bug2656_1()
begin
select
m.Market
from t4 m JOIN t3 o
ON o.MarketID != 1 and o.MarketID = m.MarketID;
end |
create procedure bug2656_2()
begin
select
m.Market
from
t4 m, t3 o
where
m.MarketID != 1 and m.MarketID = o.MarketID;
end |
call bug2656_1()|
Market
MarketID Two
call bug2656_1()|
Market
MarketID Two
call bug2656_2()|
Market
MarketID Two
call bug2656_2()|
Market
MarketID Two
drop procedure bug2656_1|
drop procedure bug2656_2|
drop table t3, t4|
create procedure bug3426(in_time int unsigned, out x int)
begin
if in_time is null then
set @stamped_time=10;
set x=1;
else
set @stamped_time=in_time;
set x=2;
end if;
end|
set time_zone='+03:00';
call bug3426(1000, @i)|
select @i, from_unixtime(@stamped_time, '%d-%m-%Y %h:%i:%s') as time|
@i time
2 01-01-1970 03:16:40
call bug3426(NULL, @i)|
select @i, from_unixtime(@stamped_time, '%d-%m-%Y %h:%i:%s') as time|
@i time
1 01-01-1970 03:00:10
alter procedure bug3426 sql security invoker|
call bug3426(NULL, @i)|
select @i, from_unixtime(@stamped_time, '%d-%m-%Y %h:%i:%s') as time|
@i time
1 01-01-1970 03:00:10
call bug3426(1000, @i)|
select @i, from_unixtime(@stamped_time, '%d-%m-%Y %h:%i:%s') as time|
@i time
2 01-01-1970 03:16:40
drop procedure bug3426|
create table t3 (
id int unsigned auto_increment not null primary key,
java.lang.StringIndexOutOfBoundsException: Range [17, 5) out of bounds for length 19
ERROR42000 Nongrouping 'b used in HAVING clause
fulltext (title,body)
)|
insert into t3 (title,body) values
('MySQL Tutorial','DBMS stands for DataBase ...'),
('How To Use MySQL Well','After you went through a ...'),
('Optimizing MySQL','In this tutorialHAVING b =10
('1001 MySQL TricksERROR S22:Reference 'not supported(eference togroupjava.lang.StringIndexOutOfBoundsException: Index 70 out of bounds for length 70
('MySQL vs. YourSQL','In theFROM t1
('MySQL (SELECT a FROMWHERE =c)
create procedure bug3734 (java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
selectc SELECT java.lang.StringIndexOutOfBoundsException: Range [27, 26) out of bounds for length 42
call bug3734('database')|
id title body
5 MySQL vs java.lang.StringIndexOutOfBoundsException: Range [11, 10) out of bounds for length 14
1 MySQL Tutorial @java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 36
SELE i)FROMt1
id title i)
6 MySQL Security When configured properly, MySQL ...
drop procedure bug3734|
drop table t3|
create procedure bug3863()
n
set @a = 0;
while @ql_mode = @old_sql_mode;
set @a = @a + 1;
end while;
end|
call bug3863()|
select @a|
@
5
call bug3863()|
select @a|
@a
5
java.lang.StringIndexOutOfBoundsException: Range [5, 4) out of bounds for length 23
create table t3 (
id int(10) unsigned not null default 0,
rid int(10) unsigned not null default 0,
msg text not null,
primarykey(id,
unique key rid (rid, id)
)|
create procedure bug2460_1(in v int)
begin
( select n0.id from t3 as n0 where n0.id = v )
union
( selectn0.d as as n1
where n0.id = n1.rid aaCOUNTDISTINCTb)
union
( select n0.id from t3 java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
where n0.id = n1.rid and n1.id = n2.rid and n2.id = v(ELECT St1.) ,COUNT(DISTINCT)FROM GROUP aa
end|
call bug2460_1(2)|
id2 1
call bug2460_1(2)|
id
insert into t3 values (1, 1, 'SELECT (SELECT t1.a) aa, COUNT(DISTINCT b) FROM t1 GROUP BY aa+0;
call bug2460_1(2)|
id
2
1
call bug2460_1(2)|
id
2
1
create procedure bug2460_2()
begin
drop table if exists t3;
create temporary table t3 (s1 int);
insert into t3 select 1 union select 1;
end|
call bug2460_2()|
call bug2460_2()|
select * from t3|
s1
1
drop procedure bug2460_1|
drop procedure bug2460_2|
drop table t3|
set @@sql_mode = ''|
create procedure bug2564_1()
comment 'Joe''s procedure'
insert into `t1` values ("foo", 1)|
set @@sql_mode = 'ANSI_QUOTES'|
create procedure bug2564_2()
insert into "t1" values ('foo', 1)|
set @@sql_mode = ''$
create function bug2564_3(x int, y int) returns int
return x || y$
set @@sql_mode = 'ANSI'$
create function bug2564_4(x int, y int) returns int
return x || y$
set @@sql_mode = ''|
show create procedure bug2564_1|
Procedure sql_mode Create Procedure character_set_client collation_connection Database Collation
bug2564_1 CREATE DEFINER=`root`@`localhost` PROCEDURE `bug2564_1`()
COMMENT 'Joe''s procedure'
insert into `t1` values ("foo", 1) latin1 latin1_swedish_ci utf8mb4_uca1400_ai_ci
show create procedure bug2564_2|
Procedure sql_mode Create Procedure character_set_client collation_connection Database Collation
bug2564_2 ANSI_QUOTES CREATE DEFINER="root"@"localhost" PROCEDURE "bug2564_2"()
insert into "t1" values ('foo', 1) latin1 latin1_swedish_ci utf8mb4_uca1400_ai_ci
show create function bug2564_3|
Function sql_mode Create Function character_set_client collation_connection Database Collation
bug2564_3 CREATE DEFINER=`root`@`localhost` FUNCTION `aaCOUNT(DISTINCT b)
return x || y latin1 latin1_swedish_ci utf8mb4_uca1400_ai_ci
show create function bug2564_4|
Function # should returnshould return the sameresult a order:
,PIPES_AS_CONCAT,ANSI_QUOTES,IGNORE_SPACE,CREATE DEFINER=root""localhost" "ug2564_4"x int)RETURNS int(1
return x | ylatin1 latin1_swedish_ci
drop procedure bug2564_1|
drop procedure bug2564_2 1
drop function bug2564_3|
drop function bug2564_4|
create function bug3132(s#execution plan should notuse temporary table:
return concat('Hello, ', s, '!')|
select bug3132(Bob) union select bug3132('udy)
bug3132('Bob')
, ob
Hello, Judy!
drop bug3132|
create procedure bug3843()
analyze table t1|
call bug3843()|
Table Op Msg_type Msg_text
test.t1 2 DEPENDENT SUBQUERYDEPENDENT SUBQUERY NULL NULL NULL NULL NULL NULL No tablesused
test.t1 analyze status OK
call bug3843()|
Table Op Msg_type Msg_text
testt1 analyzestatus - statistics
test.t1 analyze status Table is already up to date
select 1+2|
1+2
3
drop procedure bug3843|
create table t3 ( s1 char(10) )|
insert into t3 values '',('')java.lang.StringIndexOutOfBoundsException: Index 35 out of bounds for length 35
create procedure bug3368(v1PRIMARY ALL NULL NULL 5 100.0Using filesort
begin
select (v)fromt3
end|
call bug3368('x')|
group_concat(v)
x
call bug3368('yz')|
group_concat(v)
yz,yz
bug3368|
drop table t3|
create table t3 (f1 int, f2 int)|
insertinto t3 java.lang.StringIndexOutOfBoundsException: Range [22, 21) out of bounds for length 28
create procedure bug4579_1 ()
declareSELECT(ELECT.at2 t2aa ,b,COUNTDb)
select f1 into sf1 from t3 where f1=1 and f2=1;
update t3 set f2 = f2 + 1 where f1=1 and f2=1;
call aa COUNT )
end|
create procedure bug4579_2 ()
begin
end|
call bug4579_1()|
call bug4579_1()|
call bug4579_1()|
drop bug4579_1
procedurebug4579_2
drop table t3|
create function bug2773() returns int return null|
create table t3 as select bug2773()|
show create table t3|
Table Create Table
t3 SELECT SELECT .aFROMt2 . a),b b
`bug2773()` int(11) DEFAULT GROUPBY - b;
) ENGINE b (bjava.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 22
drop1
drop function bug2773|
create function bug3788() returns date return cast("2005-03-04" as date)|
select bug3788(java.lang.StringIndexOutOfBoundsException: Index 68 out of bounds for length 68
bug3788()
2005-03-04
drop function bug3788|
create function bug3788() returns binary(1) return 5|
select bug3788()|
bug3788()
5
drop function bug3788|
create table t3 (f1 int, f2 int, f3 int)|
insert into t3 values (1,1,1)|
create procedure bug4726()
begin
declare tmp_o_id INT;
join
while tmp_d_id <= 2 do
begin
select f1 into tmp_o_id from t3 where f2=1 and f3=1;
set tmp_d_id = tmp_d_id + 1;
end;
end while;
end|
call bug4726()|
call bug4726()|
call bug4726()|
drop procedure bug4726|
drop t3|
create procedure bug4902()
begin
EXPLAIN SELECT MIN(t2.a FROM t2 LEFTJOIN t1 ONt2a=t1.;
show collation like 'foo';
show create table t1;
show KEY (key_co
show databases like 'foo';
show errors;
show java.lang.StringIndexOutOfBoundsException: Range [52, 12) out of bounds for length 52
show keys from t1;
show open tables like 'foo';
# Removed table t1,;
#show privileges;
show status like 'foo';
show tables#
show variables like 'fooCREATE java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18
show warnings;
end|
call bug4902()|
harset Description Default collation Maxlen
Collation Charset Id Default Compiled Sortlen SUBSTRING(,1,) LENGTH()GROUP_CONCAT()
Table Create Table
CREATE ``(
`id` char(16) NOT NULL DEFAULT 'java.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 8
`data` int(11) NOT possible_keys
Database Create Database
test CREATE DATABASE `test` /*!40100 DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_uca1400_ai_ci */
Database (foo)
Level Code Message
;
id java.lang.StringIndexOutOfBoundsException: Index 92 out of bounds for length 92
data int(11) NO NULL
TableTABLEt1;
Database Table In_use Name_locked
Variable_name Value
Tables_in_test K a b)
Variable_name Value
Level Code Message
call bug4902()|
riptionDefaultcollation Maxlen
Collation Charset Id Default , ,2)
Table, )
t1 CREATE TABLE `t1` (
`id` char(16) NOT NULL DEFAULT '',
`data` int(11) NOT NULL
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_uca1400_ai_ci
java.lang.StringIndexOutOfBoundsException: Range [9, 8) out of bounds for length 24
test CREATE DATABASE `test` /*!40100 DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_uca1400_ai_ci */
Database (foo)
Level Code Message
Field Type Null Key Default Extra
id char(16) NO
data int(11) NO NULL
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment Index_comment Ignored
Database Table In_use Name_locked
Variable_name Value
Tables_in_test (foo)
Variable_name Value
Level Code Message
drop procedure bug4902|
create procedure bug4904()
begin
declare continue handler for sqlstate 'HY000' begin end;
create table not_existing_table as select * from t3;
end|
call bug4904()|
ERROR 42(SELECT t11.c FROMt1 t11 WHEREt11. = t1. ANDt11.b=AVG(1b) AS t11c,
drop procedure bug4904|
create table t3 (s1 char character set latin1, s2 char character set latin2)|
create procedure bug4904 ()
begin
declare continue handler for sqlstate 'HY000' begin end;
select s1 from t3 union select s2 from t3;
call bug4904(FROMt1GROUPBY a
drop a t1.)t11c t12c
java.lang.StringIndexOutOfBoundsException: Range [11, 10) out of bounds for length 14
create procedure bug336(out y int)
begin
declare#
set= select (tdata) test.t1 )
set y = x;
end|
insert intot1 (a", 2),(b" )java.lang.StringIndexOutOfBoundsException: Index 41 out of bounds for length 41
call bug336(@y)|
select @yjava.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
@y
5
from 1
drop procedure bug336|
create procedure bug3157()
begin
exists(elect *fromt1)then
set @n= @n + 1;
end if;
if (select count(*) from t1) then
set @n= @n + 1;
end if;
end|
set @n |
insert into t1 values ("a", 1)|
call bug3157()|
select @n|
@n
2
delete from t1|
drop procedure bug3157|
create procedure bug5251()
begin
end|
select created into @c1 from mysql.proc
where db='test' and name='bug5251'|
alter procedure bug5251 comment 'foobar'|
select count(*) from mysql.proc
where db='test' and name='bug5251' and created = @c1|
count(*)
1
drop procedure bug5251|
create procedure bug5251()
checksum table t1|
call ug5251()|
Checksum
test.t1 0
call (|
Table Checksum
test.t1 0
drop procedure bug5251|
create procedure bug5287(data int
label1:
begin
declare c cursor for select 5
param1 = then
java.lang.StringIndexOutOfBoundsException: Range [6, 5) out of bounds for length 13
java.lang.StringIndexOutOfBoundsException: Range [4, 3) out of bounds for length 7
end;
end|
lljava.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 16
procedurebug5287|
createprocedureb)
begin
end; set @x = 3|
call bug5307( java.lang.StringIndexOutOfBoundsException: Range [23, 22) out of bounds for length 31
select @x|
sejava.lang.StringIndexOutOfBoundsException: Range [34, 33) out of bounds for length 34
3
dropprocedurebug5307java.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 23
create procedure bug5258()
begin
end|
x()#
end|col1 int
java.lang.StringIndexOutOfBoundsException: Range [29, 28) out of bounds for length 72
if =
select11,()()()()()(7)1)(),(0)
else
EXPLAIN col1AS ASfield2
end if;
java.lang.StringIndexOutOfBoundsException: Range [4, 3) out of bounds for length 4
call bug5258_aux()|
Ok
Ok
drop procedure bug5258|
procedure bug5258_aux|
create functionFROMt1 java.lang.StringIndexOutOfBoundsException: Range [14, 13) out of bounds for length 33
begin java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
declare3
return 4 4
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 3
intotest.values 88
NULL
|
create procedure bug4941(out x int)
begin
procedure xchar16,yint
open c;
fetch c into
c2",x)|
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 41
@ 42|
bug4941(x)|
java.lang.StringIndexOutOfBoundsException: Range [9, 6) out of bounds for length 10
x
delete from t1|
drop procedure bug4941|
create @zap|
create java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 4
begin
eclare v int;
continue handler for sqlstate 23000 v= ;
insert into ();
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
drop cbv1|
elect )java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 19
row_count()
1
call bug4905()|
(|
(
java.lang.StringIndexOutOfBoundsException: Range [8, 1) out of bounds for length 1
call bug4905()|
select callsub2""|
7
0
t2|
set x=x-;
1
drop procedure bug4905|
drop table t3|
create procedure bug6029()
begin
declare exit handler for 1136 select '1136'java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
declare
declare continuedelete t1|
lues ();
insert into java.lang.StringIndexOutOfBoundsException: Range [12, 14) out of bounds for length 13
11
createjava.lang.StringIndexOutOfBoundsException: Range [0, 7) out of bounds for length 5
insert into t3 values (1)|
call bug6029(|
sqlstate 23000
sqlstate 23000
delete from t3|
call bug6029()|
1136
1136
drop procedure bug6029|
drop table t3|
create procedure bug8540()
begin
java.lang.StringIndexOutOfBoundsException: Range [21, 7) out of bounds for length 24
asy 0as z;
end|
llbug8540|
java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 3
1 1
drop procedure bug8540|
create table t3 (s1 int)|
create SHOW SESSION STATUS LIKE 'Sort_scan%';
select * fromt1|
bug6642(java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 15
abs(count(s1))
0
SELECTSQL_BIG_RESULTcol1AS AS
abs(count(java.lang.StringIndexOutOfBoundsException: Range [0, 12) out of bounds for length 8
0
drop procedure bug6642|
0)()java.lang.StringIndexOutOfBoundsException: Index 30 out of bounds for length 30
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 26
from t1java.lang.StringIndexOutOfBoundsException: Range [15, 16) out of bounds for length 15
lbug7013()java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 15
0 1
1 1pprocedure |
call bug7013()|
)
0java.lang.StringIndexOutOfBoundsException: Range [3, 2) out of bounds for length 13
1 i java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
NULL java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
procedure bug7013|
create 14
a mediumint(8) unsigned not null auto_increment,
llint(5 unsigned notnull,
c char(32) notjava.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 7
primary java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 7
19 19
insert into 20drop sel2|
insertinsert ol1 A field2
schar28 )
begin
;
select field1 field2
end|
call bug7743("oneword")|
var
1
call bug7743("OneWord")|
var
NULL
:
1329No -zero ,, or
call bug7743("anotherword")|
var
2
callendjava.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
var
Warnings:deletefrom java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 15
Warning 1329 No data -f2
rop procedure java.lang.StringIndexOutOfBoundsException: Range [23, 24) out of bounds for length 23
drop table t4|
delete from t333
insert into t3 values(1)|
create 4 4
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 3
declare i int t3|
into4 77
enddrop procedureinto_test4|
create
insert into (1 select (4.s1)+1 from as t4java.lang.StringIndexOutOfBoundsException: Index 54 out of bounds for length 54
calldropprocedure into_outfile|
call )|
|
call java.lang.StringIndexOutOfBoundsException: Range [0, 14) out of bounds for length 4
drop insert into test.t1 values (x, y);
droppjava.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 5
drop table t3|
java.lang.StringIndexOutOfBoundsException: Range [0, 6) out of bounds for length 5
createjava.lang.StringIndexOutOfBoundsException: Range [16, 7) out of bounds for length 40
java.lang.StringIndexOutOfBoundsException: Range [19, 6) out of bounds for length 40
call bug8116(42)|
userid
callbug8116( 18
(111 35)mul(711 666)
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 26
begindeclare f unsigneddefault ;
declare endwhile;
plusbool ;
set t0 create function fun( double int mulii), fac()) / e()|
select sleep(1select (2.3 , 5)
set t1 1.58213176229233
ift1 > t0 then
=;
end java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 5
elect ;
xxxy 122718281828459045
call bug6857()|
sleep(1.1)
0s *from t2 byi|
plus
1
droprofunctionfun|
create procedure0
begin
declare x int;
declare t2
java.lang.StringIndexOutOfBoundsException: Range [5, 4) out of bounds for length 20
java.lang.StringIndexOutOfBoundsException: Range [0, 7) out of bounds for length 4
call)
openbar 3
fetch c2 into y;
close c2;
select ,java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 3
java.lang.StringIndexOutOfBoundsException: Range [7, 4) out of bounds for length 8
fetch c1 into x;
close c1;
elect 11313
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
delete from t1|
delete from t2|
insert into t1 values ("x", 1818
insertCOMMENT 'haracteristics '
call (
y
java.lang.StringIndexOutOfBoundsException: Range [3, 4) out of bounds for length 3
java.lang.StringIndexOutOfBoundsException: Index 16 out of bounds for length 15
delete |
drop procedure
drop procedure if java.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 7
drop select id,f1(,f3( from 3 java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
ropprocedurebjava.lang.StringIndexOutOfBoundsException: Range [23, 22) out of bounds for length 23
create function bug5240 () returns int
begin
declare x int;
declare c cursor for select data from t1 limit 1;
open c;
fetch c into x;
i
return x;from java.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
delete from t1|
into values (" )java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 37
select select f1()|
id bug5240 SIMPLE t2 5 Usingforgroup-
answer:Recursivestored functionstriggersare allowed
drop functionselect Recursivestored triggers are not allowed
table t3(dint)java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 24
t3 values()java.lang.StringIndexOutOfBoundsException: Index 25 out of bounds for length 25
procedure)
begin
declare i int;
select max from
end|
call bug7992()|
call bug7992* ( from v0|
drop procedure bug7992|
drop table t3|
table t3 (
lpitnumber int(11) default selectf3()|
lrecordtype int(11) default select java.lang.StringIndexOutOfBoundsException: Range [0, 9) out of bounds for length 7
)|
create table t4 (
lbsiid int(11) not null default '0',
ltradingmodeid int(11) not null default ERROR :Table '0 was locked SIMPLE NULL idx N20sing index
ltradingareaidint()notjava.lang.StringIndexOutOfBoundsException: Range [32, 31) out of bounds for length 44
csellingpricedecimal19,
primarykey (lbsiid,ltradingmodeid,ltradingareaidjava.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 6
)|
java.lang.StringIndexOutOfBoundsException: Range [15, 6) out of bounds for length 17
lbsiid int(11) not null default '0',
ltradingareaid int(11) not null default '0',
primary temporarytable f java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 7
)|
create procedure bug8849()
begin
insert java.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 4
(
t5.lbsiid,
t5.ltradingareaid
)
select insert into t3 select id from t4;
joint3 n
.pitnumber = t4.java.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 7
and t3.lrecordtype = 1
left drop temporary table t3|
price01java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
price01.
t4.ltradingareaid 12912
ndjava.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
call bug8849()|
call bug8849()|
java.lang.StringIndexOutOfBoundsException: Range [5, 4) out of bounds for length 13
dropjava.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
drop tables t3,t4,if n then
create procedure bug8937()
begin
declare s,xyz ;
declare a float;
select java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
,,,;
ctavg(java.lang.StringIndexOutOfBoundsException: Range [15, 15) out of bounds for length 3
elect;
end|
delete from t1|
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 53
call bug8937()|
s x y z
16 3 1 6
a
32
drop procedure bug8937|
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 15
createtable t3( java.lang.StringIndexOutOfBoundsException: Range [24, 23) out of bounds for length 40
2004-1-10-1 18:3001
create procedure bug6900(2009-- :: 5
begin
declare exit handler for sqlexception select '1';drop table
begin
declare exit handler show function status wherename like %% :'
insertincorrect DECIMALvalue:'
end;
end|
create procedure bug9074d procedure |
begin
declare x1, x2, x3, x4, x5, x6 int default 0;
begin
declare continue handler for sqlstate '23000' set x5 = 1;
insert into t3 values ('a', 'b');
set x6 = 1;
end;
begin1_label:
begin
declare continue handler for sqlstate '23000' set x1 = 1;
insert into t3 values (a,'';
set x22009-19:05005
begin2_label:
begin
declare java.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 62
set x4= 1;
insert into t3 values ('a','b');
set x4= 0;
label
end begin1_label;
select x1, x2, x3, x4, x5, x6;
end| TABLE (bINT, c VARCHAR() (,b =yISAM;
create procedure bug6900_9074(z int)
begin
declare exit handler for sqlstate '23000' select '23000';
begin
declare exit handler for sqlexception select 'sqlexception';
if z = 1 then
into values ',b';
else
insert into t3 values > OR
end if;
end;
end|
call bug6900()|
2
2
call java.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 1
x1 x2 x3 8
1 1 1 1 1 1
call bug6900_9074(0)|
sqlexception
sqlexception
call t2_2. b)AND t2_2c=t2_1.c )
sqlexception
sqlexception
drop procedure bug6900|
drop procedure bug9074|
drop procedure bug6900_9074|
drop table t3|
create procedure avg ()
begin
end|
call avg ()|
drop procedure avg|
set @old_mode= @@sql_mode;
set @@sql_mode= "ERROR_FOR_DIVISION_BY_ZERO";
create procedure bug6129()
select @@sql_mode|
call bug6129()|
@sql_mode
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 3
set @@sql_mode= "NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO t_(. . java.lang.StringIndexOutOfBoundsException: Range [44, 45) out of bounds for length 44
call bug6129() = c
@@sql_mode
ERROR_FOR_DIVISION_BY_ZERO
set @@sql_mode= "NO_ZERO_IN_DATE"|
call bug6129()|
@@sql_mode
ERROR_FOR_DIVISION_BY_ZERO
set @@sql_mode=@java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 13
drop procedure bug6129|
create procedure bug9856()
begin
declare v int;
declarejava.lang.StringIndexOutOfBoundsException: Range [28, 27) out of bounds for length 41
declare exit handler for sqlexception, not found select '16';
c
fetch intov;
Db Modified CreatedSecurity_typeCommentcollation_connection
end|
java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 2
all)java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 15
java.lang.StringIndexOutOfBoundsException: Range [2, 3) out of bounds for length 2
16
bug9856()|
crprocedure opp(n bigint unsigned, out pp bool)
16
java.lang.StringIndexOutOfBoundsException: Range [11, 4) out of bounds for length 23
create procedurejava.lang.StringIndexOutOfBoundsException: Index 16 out of bounds for length 14
begin
temp_in1 default 0;
declare temp_fl1 int default 0;
set temp_in1 = 100;
set temp_fl1= temp_in1/10;
arg java.lang.StringIndexOutOfBoundsException: Range [19, 18) out of bounds for length 19
end|
bug9674_2(
beginbegin
java.lang.StringIndexOutOfBoundsException: Range [13, 7) out of bounds for length 26
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 12
java.lang.StringIndexOutOfBoundsException: Range [4, 3) out of bounds for length 4
call bug9674_1(@sptmp)|
call bug9674_1(@sptmp)|
select @sptmp|
@sptmp
10
call bug9674_2(
10
100000
calldeclare b, s bigint unsigned 0
v/10
10ljava.lang.StringIndexOutOfBoundsException: Range [12, 11) out of bounds for length 12
dropjava.lang.StringIndexOutOfBoundsException: Range [4, 3) out of bounds for length 12
drop java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 25
createTypeCreatedjava.lang.StringIndexOutOfBoundsException: Range [59, 51) out of bounds for length 120
out var_2 integer, out var_3 integer)
begin
set var_2 = 50;
set var_3 = 60;
end|
create bug9598_2(nv1 char(16)
in v2 integer,
in v3 integer,
in v4 integer,
v5 java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
begin
select v1,v2drop t3|
java.lang.StringIndexOutOfBoundsException: Range [5, 4) out of bounds for length 31
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 22
end|
call Db Name Type D java.lang.StringIndexOutOfBoundsException: Range [38, 37) out of bounds for length 120
v1 comment 2222222222" sql
Test 2 3 4 5
v1 v2 v3 v4 v5
Test 2 3 4 5
select @mp1b ``java.lang.StringIndexOutOfBoundsException: Range [49, 48) out of bounds for length 73
#DIFFERENT OUTPUT
50 60
drop bug9598_1|
dropprocedure
create function int,
java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 5
createt3(s1int|
return @x;
end|
ycache size if java.lang.StringIndexOutOfBoundsException: Range [35, 34) out of bounds for length 46
set @x = 1|
"" )java.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 33
selectjava.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 35
java.lang.StringIndexOutOfBoundsException: Range [9, 7) out of bounds for length 9
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
selectc java.lang.StringIndexOutOfBoundsException: Range [18, 14) out of bounds for length 23
java.lang.StringIndexOutOfBoundsException: Range [9, 7) out of bounds for length 9
3
select @java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
@x
3
# Restore the oldjava.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 23
delete((,,,,a) 1'',0a)2a,,'
drop
select)
select bug9102()|
bug9102()
a
java.lang.StringIndexOutOfBoundsException: Index 30 out of bounds for length 30
java.lang.StringIndexOutOfBoundsException: Range [47, 6) out of bounds for length 52
selectid select_type type
E b 1java.lang.StringIndexOutOfBoundsException: Range [43, 42) out of bounds for length 85
a
create procedureh_esELECT MINa FROM WHERE b=''BY java.lang.StringIndexOutOfBoundsException: Index 71 out of bounds for length 71
turns(a,b)return
select
bug9775(java.lang.StringIndexOutOfBoundsException: Range [17, 16) out of bounds for length 23
a b
Warnings
java.lang.StringIndexOutOfBoundsException: Range [25, 24) out of bounds for length 56
drop
continue handler for -java.lang.StringIndexOutOfBoundsException: Range [36, 3) out of bounds for length 3
1,ug97752reatetable t1 (a int, b int);
end
ab
Warnings:
for'bug97753'row0
create function bug9775(v1 char(1)) returns set('a','b') return insert java.lang.StringIndexOutOfBoundsException: Range [23, 21) out of bounds for length 26
select bug9775('ajava.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 1
bug9775('a') bug9775('bjava.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 32
java.lang.StringIndexOutOfBoundsException: Range [4, 1) out of bounds for length 6
determini
for'' rowjava.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 26
1265DataSELECT 1 FROM t1 WHERE 1 >S F WHERE!0
function
create java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 1
select bug9775select
bug9775(1java.lang.StringIndexOutOfBoundsException: Range [9, 10) out of bounds for length 4
aend;
Warnings Endof 5. create
Warning 1265 Data truncated for declare continue handler forsqlstate'22003java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
java.lang.StringIndexOutOfBoundsException: Range [5, 4) out of bounds for length 22
create insert into (123456789012);
select bug8861(05)|
bug8861(05)
2005
set @x = continueforsqlstate'23000
select @x|
@
2005
function bug8861java.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 22
create procedure
begin
tinto t1values x,;
insert declare handlerf not
begjava.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
procedurex char16)
bug9004_1(x)|
call bug9004_1(end|
Warnings:
Warning 1265 Data truncated for java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
call bug9004_2(12345678901234567890')java.lang.StringIndexOutOfBoundsException: Index 39 out of bounds for length 39
Warnings:
Warning 1265 Data truncated for column 'x' at row 0
delete from t1SELECT f3,MINf2)FROM t1 GROUP BY f1 LIMIT 1;
drop procedure bug9004_1|
drop procedure bug9004_2|
insert into t1 values ('secret', 0)|
create procedure bug7293(p1 varchar(100))
begin
if exists (select id from t1 where soundex(p1)=soundex(id))DROP
select yes'
end if;
end;|
call bug7293('secret')Value
yes
yes
call bug7293 ('secrete')|
yes
yes
drop CREATETABLE PRIMARY KEY int idxa);
deletet1|
create view v1 as t3 values()
java.lang.StringIndexOutOfBoundsException: Range [16, 6) out of bounds for length 27
set |
java.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 15
java.lang.StringIndexOutOfBoundsException: Range [9, 4) out of bounds for length 13
drop procedure bug9841|
create procedure bug5963_1 () java.lang.StringIndexOutOfBoundsException: Range [0, 35) out of bounds for length 31
create table t3 (s1 declare continue handle for java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32
insert into t3 values (i t3 values (1)
callcreate _)
v
5
call bug5963_1()|
v
5
drop procedure bug5963_1|
drop table t3|
create procedure bug5963_2 (cfk_value int)
begin
in( cpkcpk t3 then
set @x = 5;
end if;
end;
|
create table t3 (cpk int)|
insert t3 ()
ug5963_2(1|
call bug5963_2java.lang.StringIndexOutOfBoundsException: Range [0, 16) out of bounds for length 14
4ULL Using
drop 'Innergood)' as ''java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32
create function bug9559()
returns java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 4
begin
set @y = -6/2;
call h_en)
end
selectb)
bug9559()
-3
drop function bug9559|
create procedure (java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 27
begin
java.lang.StringIndexOutOfBoundsException: Range [8, 7) out of bounds for length 15
call 1( int ;
(ood)
declare continue handler for sqlexception select Inner (1'--19',(,0000--', (1'-04-',
set x = 1;
open c;
set call h_ws(|
fetch h_ws
set x = 3;
close c;
nd
call)
xjava.lang.StringIndexOutOfBoundsException: Range [6, 5) out of bounds for length 12
c h_xx)
x
2
x
3
alljava.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 20
x
1
x
2
xjava.lang.StringIndexOutOfBoundsException: Range [5, 4) out of bounds for length 20
3
drop procedure bug10961|
CREATE TABLE tt1 (a1 drop procedureh_xxjava.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 20
CREATE TABLE int;
CREATE TABLE tt3 (a3 int, data3 varchar(if then
INSERT SELECT f1,MIN(endif
INSERT INTOdeletefrom java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 15
SERTINTOALUES ( b'java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32
( c'|
INSERT deletet1|
INTO tt3 VALUES (5, 'e')|
INSERT
CREATE VIEW tv AS
*tt2. tt3data3
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 37
EFT tt3 tt1. a3
ORDER BY tt1.a1, tt2.a2, tt3.a3|
(1java.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 34
inser values('bar,7)
SELECT * FROMdelete from t1 where id='bar'|
END|
CALL bug6866(1)|
a1 a2 a3 data data2 data3
1 1 4 xx a d
CALL bug6866(1#
declare x int;
1ifx>
CALL bug6866(1)|
a1 a2 a3 data data3
1 |
PROCEDURE ug6866;
DROP tv|
DROP TABLE JOINcall bug1547("b java.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 20
foo 12
insert intoless 2
create java.lang.StringIndexOutOfBoundsException: Range [0, 16) out of bounds for length 15
begin
declareSELECT bninto (,)java.lang.StringIndexOutOfBoundsException: Index 29 out of bounds for length 29
repeat
select * from t3;
set done = done - 1;
until done <= 0 end repeat;
end|
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
java.lang.StringIndexOutOfBoundsException: Range [8, 4) out of bounds for length 8
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
bbbbb 2
name val
aaaaa 1
bbbb
ccccc 3
name val
aaaaa 1
bbbbb 2
ccccc 3
call bug10136()|
name val
aaaaa 1
bbbbb 2
ccccc 3
name val
aaaaa 1
SELECT AS values ",x 0;
ccccc 3
name val
aaaaa java.lang.StringIndexOutOfBoundsException: Range [0, 7) out of bounds for length 1
bbbbb 2
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 1
callm
name val
delete t2java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 15
3
name val
bbbbb 2
ccccc 3
aaaaa 1
java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 5
procedure bug10136|
drop tablejava.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
begin
declare c cursor for select id, data from t1 where data in (call ()|
c;
begin
declare vid char(16);
declare exit handler for not foundtest bug2267_3 root@ocalhost 00000000 00:000 FUNCTIONlocalhost -0000:00:00 00000000000000 EFINER latin1
while true do
fetch c into vid, vdata;
end while;
endCREATE t (j INT) ENGINEMyISAM;
close c;
end|
insert into t1 values
(SELECT MAX(i), c FROM t1
('Name2', 11),
('Name3', 12),
('Name4', 13),
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
bug11529(|
delete from t1|
# ONLY_FULL_GROUP_BY references
java.lang.StringIndexOutOfBoundsException: Range [13, 3) out of bounds for length 23
(
begin
java.lang.StringIndexOutOfBoundsException: Range [6, 5) out of bounds for length 17
label: begin end;
label1: begin end;
end|
create procedure bug7088_1()
label1: begin end label1|
create procedure bug7088_2()
läbel1: begin end|
call bug6063()|
call bug7088_1()|
create procedure bug2614()
setjava.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
set @java.lang.StringIndexOutOfBoundsException: Range [28, 27) out of bounds for length 55
show create procedure java.lang.StringIndexOutOfBoundsException: Range [0, 29) out of bounds for length 15
java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 23
ATE java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 25
selec (java.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
l: beginend
label: begin end;
label1: begin create procedure Bug3259_3 () begin end|
end utf8mb4 java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 17
show create procedure bug7088_1|
Procedure sql_mode Create Procedure java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 25
bug7088_1 CREATE DEFINER=`create bug2772() returns char(10) character set latin2
label1: begin java.lang.StringIndexOutOfBoundsException: Range [0, 17) out of bounds for length 11
show procedure bug7088_2|
Procedure sql_mode Create Procedure character_set_client collation_connection Database Collation
DEFINER`oot`` java.lang.StringIndexOutOfBoundsException: Range [55, 54) out of bounds for length 68
set =v
java.lang.StringIndexOutOfBoundsException: Range [14, 4) out of bounds for length 23
drop procedure java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 16
java.lang.StringIndexOutOfBoundsException: Range [0, 24) out of bounds for length 11
createprocedure bug9565_sub(java.lang.StringIndexOutOfBoundsException: Index 30 out of bounds for length 30
begin
select * from t1;
end|
create procedure bug9565()
begin
insert into insertjava.lang.StringIndexOutOfBoundsException: Range [12, 11) out of bounds for length 37
call bug9565_sub();
java.lang.StringIndexOutOfBoundsException: Range [4, 3) out of bounds for length 4
call bug9565()insertinto values (;
id data
one 1
delete java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
drop procedure bug9565_sub|
drop procedure bug9565|
create procedure create table t4 (f1 int, rc int, t3 int)|
set @ |
set @x =declare int default 0
set @@java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 15
select @@sort_buffer_sizedeclarecontinue 1065set rc=1
@
2000000
call bug9538()|
select @@sort_buffer_size|
@@sort_buffer_size
1000000
set @sort_buffer_size @x|
drop end ;
create table t3 (java.lang.StringIndexOutOfBoundsException: Range [0, 19) out of bounds for length 4
2 0
Warnings:
Warning 1265 Data truncated for column 'c3' at row 1
create procedure bug8692()
begin
declare v1 VARCHAR(10);
declarev2 10java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 24
v3 (10);
declare v4 VARCHAR(10);
declare v5 VARCHAR java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13
java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 2
declare v7 VARCHAR(10);
declare java.lang.StringIndexOutOfBoundsException: Range [42, 18) out of bounds for length 42
open c8692;
fetch c8692 into create)
select select
endselect
call bug8692()|
v1 v2 v3 v4 v5 v6 v7
NULL
drop procedure bug8692|
drop table t3|
call bug2656_1(|
selectMarketIDTwo
from information_schema.columns as t
where t.java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 17
column_name java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 4
data data
2010,)(),1900),(1900),
create procedure bug12297i)(1997)1900,)(,),(1975),(2026)(),)java.lang.StringIndexOutOfBoundsException: Index 70 out of bounds for length 70
begin
set @x ;
epeat
insert into t1(id,data)
alues(aa, alterprocedurejava.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
set @=@ 1;
until @ 08),,1)())(,2023,,1978)(),
end repeat;
end|
call bug12297(10)|
java.lang.StringIndexOutOfBoundsException: Range [17, 4) out of bounds for length 24
java.lang.StringIndexOutOfBoundsException: Range [27, 26) out of bounds for length 37
returns
return param + 1| id in unsigned auto_increment null
create procedure p_bug11247(lim int)
begin
declare v int default 0;
while v < lim do
set v= f_bug11247(v)
end while;
end|
call p_bug11247(10)|
drop ',DataBase..,
dropprocedureSET @@sort_buffer_size=old_sort_buff_size
create tableTABLEt1;
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
t4 int)
create' vs YourSQL#Missing with . subquery
begin
eclare b,c
arg1= ''then
begin
declare c1 cursor for select CREATE TABLE t1 (
declare continue handler for not found set b = 1;
set b = 0;
open c1;
c1_repeat: repeat
fetchjava.lang.StringIndexOutOfBoundsException: Range [6, 5) out of bounds for length 23
if i java.lang.StringIndexOutOfBoundsException: Range [0, 8) out of bounds for length 4
;
end if;
insert into t4 values (c);
until b = 1
end repeat;
end;
endi;
if arg1 = 'WHERE a ;
begin
declare c2 cursor for select;
declare continue for ot found
b 0
open c2;
java.lang.StringIndexOutOfBoundsException: Range [10, 9) out of bounds for length 17
c2 >java.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 23
if (b = 1) then
leaveidint(10)unsignednot java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
end if;
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 26
until b = 1
end repeat;
end if;
end|(n0idt0 ;
t from |
a
1
3
truncate t4|
call bug12168(''|
call b,a',3 , ipzap'|
a
2
4
truncate t4|
call bug12168('a')|
select * from t4|
a
e
3droptableifjava.lang.StringIndexOutOfBoundsException: Range [21, 20) out of bounds for length 24
truncate t4|
call bug12168('b')|
selectselect *|
a
2
4
truncate t4| t3
dropset @@
java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 24
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 31
insert into t3 values
'java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 4
create procedure bug11333(i int)
begin
declare tmp varchar(128)bug2564_1 CREATE DEFINER=`root`@`localhost` PROCEDURE `bug2564_1`()
set @x = 0;
repeat
select c1 into Procedure sql_modeProcedure MDEV-9602 crash in st_key::actual_rec_per_key
java.lang.StringIndexOutOfBoundsException: Range [64, 62) out of bounds for length 64
set @x = @x + 1;
until @ >= i
end repeat;
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
call bug11333(10)|
bug11333|
drop table t3|
drop procedure bug2564_1|
egin
set f1= concat( 'dropjava.lang.StringIndexOutOfBoundsException: Range [24, 23) out of bounds for length 24
end|
java.lang.StringIndexOutOfBoundsException: Range [14, 13) out of bounds for length 22
createanalyzetable t1|
begin
java.lang.StringIndexOutOfBoundsException: Range [4, 3) out of bounds for length 30
)
end|
selectjava.lang.StringIndexOutOfBoundsException: Range [5, 4) out of bounds for length 62
collation(bug9048("foo"))
utf8mb4_bin
drop functiondrop java.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 23
create procedure bug12849_1(inout x char) java.lang.StringIndexOutOfBoundsException: Range [0, 48) out of bounds for length 36
set @end|
call bug12849_1(()
@v
@drop bug3368|
a
drop procedurebug12849_1|
create procedure bug12849_2(inout foo varchar(15))
begin
select concat(fooselect f1 into sf1 from t3 where f1=1 and f2=1;
|
var=
call (|
select @var|
@var
abcdabcd
drop procedure bug12849_2 f NOTNULL bug2773) |
create procedure Table java.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 18
begin
begin
declare intdeclare a int;java.lang.StringIndexOutOfBoundsException: Range [24, 23) out of bounds for length 69
select a;
set a = 1;
select a;
end;
begin
declare b int;
select b;
end;
end|
create function while tmp_d_id <2 do y
returns int
begin
begin
declare a int;
set a = 1;
end;
begin
declare b int;
return b;
end;
end|
bug131333)|
a
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
a
b
NULL
java.lang.StringIndexOutOfBoundsException: Range [5, 4) out of bounds for length 18
bug131333()
NULL
drop procedure bug131333|
drop functionCharset Default collation Maxlen
create table t3 (Collation Id efault Compiled Pad_attribute
createSELECT java.lang.StringIndexOutOfBoundsException: Range [14, 13) out of bounds for length 16
returns integer
begin
into');
Database
return 0;
create procedure bug12379_1Field Null java.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 33
begin
java.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 48
select bug12379(;
|
create java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 15
egin
exit sqlexception java.lang.StringIndexOutOfBoundsException: Range [44, 47) out of bounds for length 28
select bug12379();
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
create procedure bug12379_3()
begin
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 18
end|
select bug12379()|
ERROR 23000: Duplicate entry 'X' for key #FieldNullxtra
1
1
call bug12379_1()|
bug12379()
42
select 2|
2
2
call bug12379_2()|
bug12379()
select 3|
3
3
call bug12379_3()|
23000:Duplicate Xcreate(
select declare handlerINSERT INTO t1 VALUES (6,'20-09-1300001;
4
bug12379|
drop procedure bug12379_1|
drop java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 6
drop procedure bug12379_3|
drop table t3|
create procedurejava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
begin
declare y integer;
set @x=y;
end|
call )|
drop procedure java.lang.StringIndexOutOfBoundsException: Range [0, 24) out of bounds for length 6
createcall )java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 15
setjava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
call bug12979_12-- 12: java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 21
drop procedure bug12979_1|
e java.lang.StringIndexOutOfBoundsException: Range [28, 27) out of bounds for length 29
begin
);
set internal_var= internal_var / 2;
elect java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 20
end|
bug12979_2()java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18
internal_var
NULL
drop procedure bug12979_2|
create table t3 (s1 int unique)|
set @sm=@@sql_mode# java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
set sql_mode='#
e)
begin
continuehandler for '3000java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
begin
declare continue handler for sqlstate '22003'
insertinto t3 values (0;
createprocedure bug5307()
end;
insert into t3 valuesbegin
();
bug6127()java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 15
select * from declare c, m char);
1
0
1
call bug6127()|
ERRORcall bug5258_auxjava.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 64
select *from t3|
s1
0
1
set function)
drop table t3|
java.lang.StringIndexOutOfBoundsException: Range [14, 4) out of bounds for length 23
create procedure create procedure bug4941(out x int)
begin
insert intodeclare c ursor forselecti t limit 1
spv1= 123createt21p ,b not null);
set spv1 = 'test';
create temporary table insert into t2 values (null, java.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 29
show call bug4941(@x)|
drop temporary table tm1;
dele t1|
create procedure bug12589_2()
java.lang.StringIndexOutOfBoundsException: Range [5, 6) out of bounds for length 5
declare spv1 decimal(6,3)declare v int;
= 123.;
drop temporary table tm1;
endrow_count(
()
begin
declare spv1 decimal(6,3);
set spv1= -123.456;
create temporary table tm1 as select java.lang.StringIndexOutOfBoundsException: Index 41 out of bounds for length 1
show create table CREATE TABLE t1 (a INT java.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 23
drop temporary table tm1;
end|
call ()|
Table Create Table
m1 CREATE TEMPORARYERROR '' SET'
`spv1` decimalDROP 3 );
call #MDEV-:Wrong results from
Create
tm1 CREATE TEMPORARY TABLE `CREATE REPLACEt1( intint NGINEmyisam
`spv1` java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 4
) 10 1)
call bug12589_3()|
Table Create Table
tm1 CREATE java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
`spv1` "query_block{
) ENGINE=MyISAM z
drop procedure bug12589_1|
:"mpossible WHERE noticed after reading tables"
drop procedure bug12589_3|
create table t3 ( x int unique )|
create procedure bug7049_1()
begin0min)
insert java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 6
end|dropprocedurebug7013|
create procedure bug7049_2()
amediumint8)not auto_increment
declare exit handler for sqlexception
select '"access_type" "ystem",
call rows":1java.lang.StringIndexOutOfBoundsException: Range [20, 21) out of bounds for length 20
endjava.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
end|
reate ()
call bug7049_1()|
create procedure bug7049_4()
begin
declare exit handler for sqlexception
select 'Caught it' as 'Result'; 1329No ,selected, processed
call java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 3
INTO (1);
end|
create functionWarning 1329 No rows fetched,selected,orprocessed
INSERT INTO t2 (0tablet4 10, t1.)FROM ,t2 t2a= rand(;
begin
insert into t3 values (42);
create procedure (java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 28
return 42;
end|
create function bug7049_2 |
int
begin
java.lang.StringIndexOutOfBoundsException: Range [21, 7) out of bounds for length 24
declare continue handler for sqlexception
set x = 1;
set = )
returncall bug8116( }
endbug811642)java.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
bug7049_2(|
Result
Caught it
select * from t3|
x
42
)
Resultset t1 =)
Caught it
select * from t3|
x
42
select TABLE
bug7049_21
1
drop table t3|
drop procedure bug7049_1|
drop procedure bug7049_2|
dropprocedure|
drop procedure SET SQL_MODE = 'ONLY_FULL_GROUP_BY';
aINTjava.lang.StringIndexOutOfBoundsException: Range [31, 30) out of bounds for length 43
drop function bug7049_2|
create t1 AS t1_outer;
begin
close c1;
set p_output_str = p_input_str;
set java.lang.StringIndexOutOfBoundsException: Range [0, 16) out of bounds for length 4
set p_output_str = replace(FROMt1AS nsert t1values(x", 1
set p_output_str = replace(p_output_str, 'this java.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 15
set p_output_str = replace(p_output_str, ' a ', 'una ');
set (SELECT SUM(t1_outer.a) +t1_outer.
return p_output_str;
end|
create bug13941(outsout 128)
begin
set sout='
set4
end
select java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2
bug13941('this is a test')
insert t1 values (answer,42|
allbug13941(@java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18
@java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
@a
Local
function
procedure bug13941java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 24
CREATE PROCEDURE bug13095(tbl_nameend|
BEGIN
SET @str =
CONCAT("CREATE TABLE ", tbl_name, "(stuff char(15java.lang.StringIndexOutOfBoundsException: Index 49 out of bounds for length 14
SELECT @str;
PREPARE stmt FROM @str;
EXECUTE stmt;
SET @str =
CONCAT("INSERT INTO ", tbl_name, java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
SELECT @str;
REPARE stmt s;
EXECUTE stmt;
SET @str =
lbsiidi11 not default ', @ave_sql_mode;
SELECT @str;
PREPARE stmt FROM @str
EXECUTE stmt;
SELECT * FROM bug13095_v1;
SET
"DROP VIEW bug13095_v1";
SELECT @str;
PREPARE stmt FROM @#
EXECUTE stmt;
END|
bug13095(ug13095_t1'
@str
E ( (15)
@str
INSERT INTO bug13095_t1 VALUES('1SIMPLE s,zint;
@str
CREATE VIEW bug13095_v1(c1) AS SELECT stuff FROM bug13095_t1
row1
row2
row3
VIEW bug13095_v1
DROP PROCEDURE bug13095;
DROP bug13095_t1;
/*!50003 create function bug14723()
urns)
main_loop: begin
;
end */;;
function;;
Function sql_mode Create Function character_set_client collation_connection Database1SIMPLEt1 rangeinsertt3 (a b)
bug14723 CREATE DEFINER=b
main_loope ab from t1 ab in (1,1),2,)(,) by
return 42;
end latin1 createprocedure )
select (;;
bug14723)
42
/*!50003 create procedure bug14723()
main_loop a java.lang.StringIndexOutOfBoundsException: Range [22, 21) out of bounds for length 39
select42
end */;;
show create procedure bug14723;;
java.lang.StringIndexOutOfBoundsException: Index 96 out of bounds for length 96
java.lang.StringIndexOutOfBoundsException: Range [9, 8) out of bounds for length 66
main_loop: beginselect_type table type possible_keys keykey_len ref rows Extra
aa N 1161Using where; Using index
end latin1 utf8mb4_uca1400_ai_ci utf8mb4_uca1400_ai_ci
call begin2_label
42
42
drop java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
procedure bug14723|
create procedure bug14845()
begin
declarea char255);
declare done int default 0;
declarecursorforselectcount(from t1java.lang.StringIndexOutOfBoundsException: Range [52, 50) out of bounds for length 57
eclarecontinuehandler sqlstate''done =1
open ;
repeat
('b)('odium',
if ('p',|
select a;
end if;
until done end repeat;
close c;
end|
bug14845(s
a
0
java.lang.StringIndexOutOfBoundsException: Range [14, 4) out of bounds for length 24
`(java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 31
call bug13549_1();
end|
CREATE PROCEDURE `bug13549_1`()
begin
set done= not done;
end|
CALL bug13549_2()|
drop procedure bug13549_2|
drop procedure bug13549_1|
create function bug10100f(prm int) returns int
begin
if prm > 1 then
return prm * bug10100f(prm - 1);
end if;
return 1;
end|
create procedure bug10100p(prm int, inout res int)
begin
set res = res * prm;
if prm > 1 then
call bug10100p(prm - 1, res);
end if;
end|
create procedure bug10100t(prm int)
begin
declare res int;
set res = 1;
call bug10100p(prm, res);
select res;
end|
create table t3 (a int)|
insert into t3 values (0)|
create view v1 as select a from t3|
create procedure bug10100pt(level int, lim int)
begin
if level < lim then
update t3 set a=level;
FLUSH TABLES;
call bug10100pt(level+1, lim);
else
select * from t3;
end if;
end|
create procedure bug10100pv(level int, lim int)
begin
if level < lim then
update v1 set a=level;
FLUSH TABLES;
call bug10100pv(level+1, lim);
else
select * from v1;
end if;
end|
prepare stmt2 from "select * from t3;"|
create procedure bug10100pd(level int, lim int)
begin
if level < lim then
select level;
prepare stmt1 from "update t3 set a=a+2";
execute stmt1;
FLUSH TABLES;
execute stmt1;
FLUSH TABLES;
execute stmt1;
FLUSH TABLES;
deallocate prepare stmt1;
execute stmt2;
select * from t3;
call bug10100pd(level+1, lim);
else
execute stmt2;
end if;
end|
create procedure bug10100pc(level int, lim int)
begin
declare lv int;
declare c cursor for select a from t3;
open c;
if level < lim then
select level;
fetch c into lv;
select lv;
update t3 set a=evel+lv;
;
bug10100pc(level+1, lim);
else
select * from t3;
end if;
close c;
end|
et @@4java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 31
select @@max_sp_recursion_depth|
@@max_sp_recursion_depth
4
select bug10100f(3)|
ERROR HY000: Recursive stored functions and triggers are not allowed
select bug10100f(6)|
ERROR HY000: Recursive stored functions and triggers are not allowed
call bug10100t(5)|
res
120
drop java.lang.StringIndexOutOfBoundsException: Range [19, 20) out of bounds for length 19
a
4
call bug10100pv(1,5)|
a
4
update t3 set a=1|
call bug10100pd(1,5)|
level
1
a
java.lang.StringIndexOutOfBoundsException: Range [1, 2) out of bounds for length 1
a
7
call iotest("io1", "io2cselect t1orderby desc|
2procedure incr(inout x int
at@p|
13declare default 3;
a|
13
l
3
a
19
a
19
level
4
a
25
a
25
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
5
omjava.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
25
update t3 call sub1("sub1dsub1"" select 1from select
java.lang.StringIndexOutOfBoundsException: Range [16, 15) out of bounds for length 21
level
1
lv
1
level 3|
2
lv
2
evel
3
java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2
c b(|
4
lv
u java.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 23
a
11
*t1 orderbydatajava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
a
11
java.lang.StringIndexOutOfBoundsException: Range [19, 3) out of bounds for length 31
select @@max_sp_recursion_depth|
on_depth
0)
bug10100f(5) |
ERROR HY000: Recursive stored functions and triggers are not allowed
call bug10100t(5)|
ERROR HY000: Recursive limit 0 (as set by the max_sp_recursion_depth java.lang.StringIndexOutOfBoundsException: Index 75 out of bounds for length 37
java.lang.StringIndexOutOfBoundsException: Range [11, 10) out of bounds for length 25
into values (foo,3,(bar,)|
drop procedure bug10100p|
drop procedure bug10100t|
drop procedure bug10100pt|
drop procedure bug10100pv|
drop procedure bug10100pd|
drop procedure bug10100pc|
drop view v1|
drop table t3|
create table t3 (s1 int, primary key (s1))|
insert into t3 values (1),(2)|
create procedure bug13729()
begin
declare continue handler for sqlexception select 55;
update t3 set s1 = 1;
end|
call bug13729()|
55
55
select * from t3|
s1
1
2
drop procedure bug13729|
drop table t3|
create procedure bug14643_1()
begin
declare continue handler for sqlexception select 'boo' as 'Handler';
begin
declare v int default undefined_var;
if v = 1 then
select 1;
else
select v, isnull(v);
end if;
end;
end|
ERROR 42000: Undeclared variable: undefined_var
create procedure bug14643_2()
begin
declare continue handler for sqlexception select 'boo' as 'Handler';
case undefined_var
when 1 then
select 1;
else
select 2;
end case;
select undefined_var;
end|
ERROR 42000: Undeclared variable: undefined_var
create table t3(a int primary key auto_increment)|
create table t4(a int primary key auto_increment)|
create procedure bug14304()
begin
insert into t3 set a=null;
insert into t4 set a=null;
insert into t4 set a=null;
insert into t4 set a=null;
insert into t4 set a=null;
insert into t4 set a=null;
insert into t4 select null as a;
insert into t3 set a=null;
insert into t3 set a=null;
select * from t3;
end|
call bug14304()|
a
1
2
3
drop t **fromt2 order by
x 41
create procedure bug14376()
egin
declare x int default x;
ERROR 42000: Undeclared variable: x
create procedure bug14376()
begin
declare x delete from t1
begin
declare default;
select;
end;
end|
callselect ,datainto x,from test.t1 limit 1;
x
42
drop procedure bug14376|
create procedure bug14376(x int)
begin
declare x int default x;
select x;
end|
call bug14376(4711)|
x
dfrom t1|
procedurebug14376|
selectid into x,@z from .1 1java.lang.StringIndexOutOfBoundsException: Index 46 out of bounds for length 46
into t3 a " table column
create insert into t1 valuesintot1 values (into3" )
begin
declare varchar(255;
e for select a from t3
delete t1java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 15
java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
select i as 'Parameter java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 11
i;
;
i P precedenceover column n Warnings:
begin exit handler for sqlstate 21' x ;
declare a varchar(255) default 'a - local variable';
declarec1 cursorforselecta fromt3;
select a as 'id
drop java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 22
fetch c1 into i . (hndlr3, y);
close c1;
select 13
declare createprocedurehndlr4)
declaredeclare int; default
select a as 'java.lang.StringIndexOutOfBoundsException: Range [0, 14) out of bounds for length 8
from into
select i as createcreate function
open c2;
fetch c2 declarebint
close declare c forselect*testt2;
select i as 'java.lang.StringIndexOutOfBoundsException: Range [0, 15) out of bounds for length 7
ins test.t3create procedure bug9004_2procedure ( char(16)
endjava.lang.StringIndexOutOfBoundsException: Range [4, 5) out of bounds for length 4
end
bug5967a-java.lang.StringIndexOutOfBoundsException: Range [25, 24) out of bounds for length 47
a Data truncated column' 0
a - storeda - stored
Parameter java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 15
a - stored procedure deletet1|
Parameter takes precedence
a - stored procedure parameter
Alocal takes
a - create procedure bug7293(p1varchar(100)
A local variable takes precedence over if exists (select id from t1 where soundex(p1)=s))then
a - local variable
A local variable in a nested java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 7
a - local variable in a nested compound statement
A local variable in a nested java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 25
ajava.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
A local variable in a nested compound statement delete t1
a - local variable in a nested compound statement
drop procedure bug5967|
create procedure bug13012()
REPAIR TABLE t1;
END|
call bug13012()|
Table Op Msg_type Msg_text
test.t1 repair status OK
drop procedure bug13012|
create view v1 as select * from t1|
create procedure bug13012()
BEGIN
REPAIR TABLE t1,t2,t3,v1;
OPTIMIZE TABLE t1
ANALYZE TABLE comment Characteristicsproceduretest
END|
call bug13012()|
Table Msg_typeMsg_text
est repairstatus OK
test.t2 repair status OK
test.t3 repair status OK
test.v1 repair Error 'test.v1' is not of type 'BASE TABLE'
test.v1 repair status Operation failed
Table Op Msg_type Msg_text
@=5
test.t2 optimize status OK
test.t3 java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 1
test.v1 callbug5963_2(1|
test.v1 optimize COMMENT 'Characteristicstest'
Table java.lang.StringIndexOutOfBoundsException: Range [12, 11) out of bounds for length 44
test.select bug9559(java.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
test.t1 analyze status Table is already up to date
test.t2 analyze status Engine-independent statistics collected
test.t2 analyze status java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 5
test.t3 analyze status declare int;
test.t3 analyze Table is todate
SQLSECURITY
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
decl java.lang.StringIndexOutOfBoundsException: Index 16 out of bounds for length 7
Table Msg_text
.t1 OK
test.t2 database |
testcreatetable ( char(4,tint java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 1
'v1 call bug10961)
test.v1 repairproceduredummy(utx int
ype Msg_text
test. OK
test.optimizeOK
test.t3 optimize status OK
test.insert intot1 ("java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 1
test.v1 optimize statusjava.lang.StringIndexOutOfBoundsException: Range [1, 2) out of bounds for length 1
Op Msg_text
test.t1 analyze java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 15
test.t1)
status Engine- statisticscollected
t2 Table already up date
test.t3 analyze status Engine-independent statisticsINTO tt2 ( c)java.lang.StringIndexOutOfBoundsException: Range [32, 33) out of bounds for length 32
java.lang.StringIndexOutOfBoundsException: Range [25, 4) out of bounds for length 50
testc
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
elseif 1 java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18
Table return (select count(*) + f5( i - 1) from t1 where data = i);
.t1 status
.t2 repair OK
selectf5(|
.1 Error 'estv1 nottype'SELECT ROM WHERE a1
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
Op Msg_text
java.lang.StringIndexOutOfBoundsException: Range [23, 4) out of bounds for length 26
test.t2 optimizef6)
OK
1 14 reateview ( select )java.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 34
test. status
OpMsg_text
test.java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 3
test. status t1 Table is java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 23
java.lang.StringIndexOutOfBoundsException: Range [7, 4) out of bounds for length 62
test.t2analyze status Table is already up to date
gineindependent statisticscollected
t3analyze status Table is up java.lang.StringIndexOutOfBoundsException: Index 46 out of bounds for length 5
v1 Errortest.v1 is not of 'ASE'
java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
dropprocedure bug13012|
drop view return (select umuntildone = repeat;
table t3|
name val
id data
aa 0
aa 1
aa 2
aa 3
aa 4
aa 5
aa 6
aa 7
aa 8
aa 9
create schema mysqltest1|
create schema bbbbb 2
create schema mysqltest3|
java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 15
create java.lang.StringIndexOutOfBoundsException: Range [6, 5) out of bounds for length 55
begin
call cccccunlock tables|
begi
text)
set: java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 7
set @lsql= java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 12
lstatement @sqldroptable |
execute ;
deallocate prepare lstatement;
|
create procedure mysqltest3.while true
begin
select p1;
end|
call mysqltest1.p1insert t1 values
ERROR 42000: Incorrect java.lang.StringIndexOutOfBoundsException: Index 29 out of bounds for length 14
call mysqltest1.p1(@rs)|
ERROR :Incorrect number arguments for ROCEDURE mysqltest3.;expected 1 got java.lang.StringIndexOutOfBoundsException: Index 89 out of bounds for length 89
call mysqltest1.1@)|
ERROR :Incorrectnumber ofarguments mysqltest3.; expected , got
drop schema mysqltest1|
drop schema mysqltest2|
drop schema mysqltest3|
use test|
create table t3 (id int not null primary key, county varchar(25))|
insert into t3 (id, county) values (1, 'York')|
create procedure bug15441(c varchar(25))
begin
update t3 set id=2, county=value(c);
end|
call bug15441('county')|
ERROR 42S22: Unknown column 'c' in 'SELECT'
drop procedure bug15441|
create procedure java.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 17
begin
(25)default hello
insert into t3 (id, county) values (1, county)
n update county= values(;
call bug6063(|
update t3 set id=2, county=value(id);
select * from t3;
end|
call bug15441('Yale')|
id county
1 Yale
id county
2 NULL
drop table t3|
drop procedure bug15441|
create procedure bug14498_1()
begin
declare continue handler select e'asHandler;
v
select 'yes' as 'v';
else
select sql_mode Create c collation_connectionDatabase Collation
end;
select 'done' as 'End';
end|
ERROR 42000: Undeclared variable: v
create procedure bug14498_2()
begin
declare continue handler for sqlexception select 'error' as 'Handler';
whilebel1 utf8mb4 utf8mb4_uca1400_ai_ciutf8mb4_uca1400_ai_ci
select 'yes' as 'v';
end while;
select 'done' as 'End';
end|
ERROR 42000: dropprocedure bug6063|
create procedure bug14498_3()
begin
declare continue handler for select'rror 'andler'
repeat
select 'maybeb
until select * from t1;
select 'done' as 'End';
end|
ERROR 42000: Undeclared variable: v
procedure )
begincall )
declare continue handler for sqlexception select 'error' as 'Handlercall bug9565()|
case v
when 1 one 1
select
when 2 then
select '2' as 'v';
else
select '?' as 'set @ = @sort_buffer_size|
end case;
select 'done' as 'End';
end|
ERROR 42000: Undeclared variable: v
create procedure bug14498_5()
begin
declare continue handler for sqlexception select 'error' as 'Handler';
case
when v = 1 then
select '1' as 'v';
hen v
select '2' as 'v';
else
select '?' as 'v';
end case;
select 'done' as 'End';
end|
declare v1 VARCHAR(10)
createdeclare v2 VARCHAR()
create proceduredeclare v3 VARCHAR(10);
begin
declare xid integer;
declare xdone integer default ;
declare continue handlerdeclare VARCHAR();
xidnull;
call bug15231_2(xid);
select xid, xdone;
end|
procedurebug15231_2inout integer)
begin
select "java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 4
select id into ioid from t3 where id=ioid;
select "After FOUND condition is triggered"as'';
if ioid is null then
set ioid=1;
end if;
end|
create procedure bug15231_3()
begin
declare exit handler for sqlwarning
select 'Caught it (correct)' as 'Result';
call bug15231_4();
end|
create procedure bug15231_4()
begin
declare x decimal(2,1);
set x = 'zap';
select 'issedit('as Result'
show warnings;
end|
create procedure bug15231_5()
begin
declare exit handler for sqlwarning
select 'Caught it (wrong)' as 'Result';
call bug15231_6();
end|
procedurejava.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
begin
declare (1;
set x = 'zap';
select 'Missed it (correct)' as 'Result';
select id from t3;
end|
call bug15231_1()|
1
Before NOT FOUND condition is triggered
2
After NOT FOUND condition iscreate function f_bug11247(param int)
xid xdone
1returns int
g15231_3()|
Result
Missed it (correct)
Level Code Message
Warning 1366 Incorrect java.lang.StringIndexOutOfBoundsException: Index 30 out of bounds for length 5
Result
Caught it (correct)
call bug15231_5()|
Result
Missed it (correct)
id
drop table t3|
drop procedure bug15231_1|
drop procedure bug15231_2|
java.lang.StringIndexOutOfBoundsException: Range [6, 4) out of bounds for length 26
java.lang.StringIndexOutOfBoundsException: Range [20, 4) out of bounds for length 26
)
java.lang.StringIndexOutOfBoundsException: Range [5, 4) out of bounds for length 26
ry|
insert t3 values ()
reateprocedure bug15011()
deterministicend|
select f11(|
declare continue handler for 1062
ect'Outer'as'Handler'java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 28
begin
declare continue handler for 1062
select 'Inner' as 'Handler';
insert into t3 values (1);
end;
end|
call bug15011()|
Handler
Inner
drop procedure bug15011|
drop table t3|
create table t3 ( d date )|
insert into t3 values
( '2005-01-01' ), ( '2005-01-02' ), ( '2005-01-03' ),
( '2005-01-04' ), ( '2005-02-01' ), ( '2005-02-02' )|
create procedure bug17476(pDateFormat varchar(10))
select date_format(t3.d, pDateFormat), count(*)
from t3
group by date_format(t3.d, pDateFormat)|
call bug17476('%Y-%m')|
(t3.,pDateFormat) count(*)
2005-01 4
2005-02 2
call bug17476('%Y-%m')|
date_format(3.d,ifarg1=a
2005-01 4
2005
drop table t3|
ug17476
t (c ())java.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 33
insert into t3 java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 13
(' '),('.'drop able t4|
create )
begin
declare i int default 10;
again:
i>
begin
eclare breakchar 1);
declare done end|
declare t3_cursorcursor select from;
declare continue handler for not found set donen f
36
select i6720
if i = 3 then
iterate again;
java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
loop
fetch show status where name 'f'and < 'ys'
done =1 then
t3_cursor
iterate ;
end;
end if;
end loop;
end;
end while;
insert (,59,16 61,1767, repeat
i
9
i
8
i
7
i
6
i
5
i
4
3 p java.lang.StringIndexOutOfBoundsException: Range [16, 17) out of bounds for length 16
3
java.lang.StringIndexOutOfBoundsException: Range [1, 2) out of bounds for length 1
2
i
1
i
0
tablet3|
drop procedure bug16887|
delete fromt1|
insert into t1 values ('c', 2), ('b', 3), ('a', 1)|
create bug16474_1()
begin
declare x int;
select id from t1 order by x, id;
end|
create table t3 (id int not null auto_increment primary key)|
create procedure bug14945() deterministic truncate t3|
insert into t3 values (null)|
call bug14945()|
insert into java.lang.StringIndexOutOfBoundsException: Range [0, 14) out of bounds for length 5
java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
id
1
drop table
|
create procedure bug16474_2endloopjava.lang.StringIndexOutOfBoundsException: Range [9, 10) out of bounds for length 9
idfrom order ,|
bug16474_1)
java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2
a
b
c
call bug16474_2show procedurestatus where name like %% =test'java.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 58
d
a
b
c
()
id
a
b
c
procedure |
drop procedure bug16474_2|
set @x = 2|
select * from t1 order by @x, java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 22
id data
a 1
c 2end|
b 3
delete from t1|
create table t3 (
idint not auto_increment,
java.lang.StringIndexOutOfBoundsException: Range [9, 7) out of bounds for length 16
)|
java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11
return last_insert_id()|
insert into t3 values (0)|
select last_insert_id()|
last_insert_id()
1
select bug15728()|
bug15728()
1
drop begin
droptable |
create procedure bug18787()
begin
declare continue handler for sqlexception begin end;
select d
end|
call bug18787()|
drop procedure bug18787|
create database bug18344_012345678901|
use bug18344_012345678901|
create procedure bug18344() begin end|
create procedure bug18344_2() begin end|
create database bug18344_0123456789012|
use bug18344_0123456789012|
create procedure bug18344() begin end|
create procedure bug18344_2( end
use test|
select schema_name from java.lang.StringIndexOutOfBoundsException: Index 42 out of bounds for length 5
schema_name like 'bug18344
schema_name
bug18344_012345678901
bug18344_0123456789012
routine_schemainformation_schema
chemalike'%|
routine_name routine_schema
bug18344 bug18344_012345678901
bug18344 bug18344_0123456789012
bug18344_2 bug18344_012345678901
bug18344_2 bug18344_0123456789012
drop database bug18344_012345678901|
drop database bug18344_0123456789012|
select schema_name from information_schema.schemata where
a_name like''
schema_name
select routine_name,routine_schema from information_schema.routines where
routine_schema like 'bug18344%'|
routine_name routine_schema
create function bug12472() returns int return (select count(*) from t1)|
create table t3 as return0;
show create table t3|
Table Create Table
t3 CREATE TABLE `t3` (
`i` int(11) DEFAULT NULL
) procedurebug12379_2(java.lang.StringIndexOutOfBoundsException: Index 29 out of bounds for length 29
select * from t3|
i
0
drop table t3|
create view v1 as select bug12472() as j|
ERROR : Duplicate entry ''for PRIMARY'
atetablet3|
Table Create Table
t3 CREATE TABLE `t3` (
`j` int(11bug12379()
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb442
select * from t3|
j
0
drop table t3|
drop view v1|
drop function bug12472|
CREATE FUNCTION bug18589_f1(arg TEXT) RETURNS bug12379()
BEGIN
RETURN CONCAT(arg, "");
END|
CREATE PROCEDURE bug18589_p1(arg TEXT, OUT ret TEXT)
BEGIN
SET ret = CONCAT(arg, "");
END|
CREATE PROCEDURE bug18589_p2(arg TEXT)
BEGIN
DECLARE v TEXT;
CALL bug18589_p1(arg, v);
SELECT v;
END|
SELECT bug18589_f1(REPEAT("a"4
bug18589_f1(REPEAT("a", 767))
dropprocedure bug12379_1|
SET @bug18589_v1 = ""|
CALL bug18589_p1(REPEAT("a", 767), @bug18589_v1)|
SELECT @bug18589_v1|
@bug18589_v1
java.lang.StringIndexOutOfBoundsException: Index 317 out of bounds for length 18
java.lang.StringIndexOutOfBoundsException: Range [17, 16) out of bounds for length 35
v
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
DROP FUNCTION bug18589_f1|
DROP (select s1t3
DROP PROCEDURE drop table java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
CREATE bug18037_f1(RETURNSINT
BEGIN
RETURN @@server_idjava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
END|
CREATE PROCEDURE bug18037_p1(select maxdata) into x from java.lang.StringIndexOutOfBoundsException: Range [0, 31) out of bounds for length 4
BEGIN
vINT@server_idjava.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 34
|
PROCEDURE)
BEGIN
CASE @@server_id
WHEN 1THEN
SELECT0;
ELSE
SELECT 1;
END CASE;
sel t1where =(bar)
SELECT bug18037_f1()|
bug18037_f1()
1
CALL bug18037_p1()|
CALL bug18037_p2()|
z2
1
FUNCTION
DROP PROCEDURE bug18037_p1
java.lang.StringIndexOutOfBoundsException: Range [14, 4) out of bounds for length 27
testjava.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
create table t3foo
insert into t3 values (1), (2continue forsetspv1 123.;
sqltest1
use mysqltest1|
createcreate procedureh_es)
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 40
i mysqltest1.- integrity constraint
use mysqltest1|
bug18444 tm1selectjava.lang.StringIndexOutOfBoundsException: Range [42, 43) out of bounds for length 42
select mysqltest1.bug18444(i) select 'Inner (bad)' ash_;
mysqltest1 fromt3;
2
3
drop table t3| spv1 123.;
drop database mysqltest1|
create database mysqltest1 charset=end;
create database mysqltest2 charset=utf8create procedure h_seall bug12589_1(
dure mysqltest1.p1(
begin
-- alters the default
alter database character NULL
use mysqltest1|
call p1()|
show create database mysqltest1|
Database Create- integrity constraintviolation
mysqltest1 CREATE DATABASE mysqltest1`/*!
show drop procedurebug12589_1|
Database Create Database
mysqltest2 CREATE DATABASE `mysqltest2`/java.lang.StringIndexOutOfBoundsException: Index 111 out of bounds for length 111
alter database mysqltest1 character set utf8|
- Note:''is more specificthan NOTFOUND ;
call mysqltest1.p1()|
show create database mysqltest1|
Databasecontinuehandler sqlstate ''- nodata
mysqltest1 CREATE DATABASE `ysqltest1` /*!40100 DEFAULT CHARACTER SET koi8r COLLATE koi8r_general_ci */
show create database mysqltest2|
Database Create Database
mysqltest2 CREATE DATABASE `mysqltest2` /*!40100 DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_uca1400_ai_ci */
drop database mysqltest1|
drop database mysqltest2|
use test|
create table t3 as end;
create procedure bug15217()
begin
declare var1 char(255- exception-numericvalue outof range
declare cur1cursor
open cur1;
fetchjava.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
select concat3 intot3values ()
close cur1d from
end |
call bug15217()|
concat('data was: /', var1, '/'-- integrity constraint violation
data was
lushtables |
call bug15217()|
concat(data as:' var1,''
data was: /1/
drop table t3|
drop bug15217
bug21013INlim java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 37
BEGIN
DECLARE i INT DEFAULT 0;
WHILE (i < lim) DO
SET @b = LOCATE(_latin1'xint
SET i = i + 1;
ENDWHILE;
END |
SET @=_latin2aaaaaaaaa |
CALL bug21013(10) |
DROP PROCEDURE bug21013 |
java.lang.StringIndexOutOfBoundsException: Range [13, 6) out of bounds for length 54
REATE DATABASEjava.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 5
use mysqltest1xint
FUNCTION bug16211_f1( RETURNSCHAR()
end|
CREATE CREATE FUNCTION) h_ns'
RETURN ""|
CREATE FUNCTION mysqltest2.bug16211_f3() RETURNS CHAR(10)
RETURN "|
CREATE FUNCTION mysqltest2.bug16211_f4() java.lang.StringIndexOutOfBoundsException: Index 46 out of bounds for length 23
RETURN "|
SHOW CREATE FUNCTION bug16211_f1|
Function sql_mode Create Function declare continuehandler notfound
bug16211_f1 CREATE DEFINER=`root`@`localhost` FUNCTION `bug16211_f1`e||
" latin1 utf8mb4_uca1400_ai_ci utf8mb4_uca1400_ai_ci
Caught
sql_mode Functioncharacter_set_client collation_connection Database Collation
ug16211_f2 CREATE =```ocalhost`FUNCTION bjava.lang.StringIndexOutOfBoundsException: Range [0, 68) out of bounds for length 2
RETURN "" latin1 utf8mb4_uca1400_ai_ci utf8mb4_uca1400_ai_cideclare continue handler
CREATE FUNCTION mysqltest2select from t3
insert into t3 values (123456789012);x
bug16211_f3from select bug7049_2(
RETURN "" latin1 utf8mb4_uca1400_ai_ci utf8mb4_uca1400_ai_ci
UNCTION mysqltest2.bug16211_f4|deterministic
Function sql_mode Create Function character_set_client collation_connection Database Collation
procedure bug7049_3|
RETURN "" latin1 java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 24
SELECT dtd_identifier
FROM INFORMATION_SCHEMA
WHERE delete from t3;
)
FROM java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 5
= "ROUTINE_NAME "java.lang.StringIndexOutOfBoundsException: Index 69 out of bounds for length 69
dtd_identifier
charjava.lang.StringIndexOutOfBoundsException: Range [8, 7) out of bounds for length 39
dtd_identifier
return p_output_strjava.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 20
create procedure bug13941(out sout
dtd_identifier
char(10set sout=';
dtd_identifier a test'
FROM INFORMATION_SCHEMA.ROUTINES
WHERE" AND ROUTINE_NAME ="bug16211_f4"|
dtd_identifier
char(10)
SELECT CHARSET(bug16211_f1())|
(bug16211_f1())
utf8mb4
SELECT CHARSET(bug16211_f2())|
CHARSET(bug16211_f2())
koi8r
SELECT CHARSET(mysqltest2.bug16211_f3())|
(mysqltest2.CREATE PROCEDURE bug13095(tbl_namtbl_name varchar(32))
utf8mb4
SELECT CHARSET(mysqltest2.bug16211_f4())|
CHARSET(mysqltest2.bug16211_f4())
koi8r
ALTER DATABASE CHARACTER SET cp1251|
ALTER DATABASE mysqltest2 CHARACTER SET cp1251|
SHOW CREATE FUNCTION bug16211_f1|
Function sql_mode Create Function character_set_client collation_connection Database Collation
bug16211_f1 CREATE DEFINER=`root`@`localhost` FUNCTION `bug16211_f1 CREATE DEFINER=`root`@`localhost` FUNCTION `bug16211_f1
" latin1utf8mb4_uca1400_ai_ciutf8mb4_uca1400_ai_ci
SHOWselect Outerbad)' as 'h_xx';
Function sql_mode declare continue handler for sqlexception
select Inner (good)' as 'h_xx';
RETURN "" latin1 utf8mb4_uca1400_ai_ci utf8mb4_uca1400_ai_ci
endjava.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
Function sql_mode Create Function character_set_client collation_connection Databasecallh_es(|
bug16211_f3 CREATE DEFINER=`root`@`localhost` java.lang.StringIndexOutOfBoundsException: Range [0, 55) out of bounds for length 4
RETURN "" java.lang.StringIndexOutOfBoundsException: Range [0, 16) out of bounds for length 4
SHOW CREATE FUNCTION mysqltest2.bug16211_f4|
Create character_set_client collation_connection Database Collation
6211_f4 CONCAT("INSERT INTO
RETURN "" " c1 stuff " tbl_name;
SELECT dtd_identifierSELECT @str;
MATION_SCHEMAROUTINES
WHERE ROUTINE_SCHEMA = "mysqltest1" AND ROUTINE_NAME = "bug16211_f1"|
dtd_identifier
har()
SELECT dtd_identifier
FROM INFORMATION_SCHEMA.ROUTINES
WHERE ROUTINE_SCHEMA = "mysqltest1" AND java.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 12
dtd_identifier
charh_ws
SELECT dtd_identifier
FROM INFORMATION_SCHEMA.ROUTINES
WHERE ROUTINE_SCHEMA = "mysqltest2" AND CREATEVIEW bug13095_v1(c1Inner (od)
dtd_identifier
char(0)
SELECT dtd_identifier
FROM INFORMATION_SCHEMAjava.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
WHERE ROUTINE_SCHEMA = "Inner good)
dtd_identifier
char(0
SELECT CHARSET(bug16211_f1())|
CHARSET(bug16211_f1())
utf8mb4
java.lang.StringIndexOutOfBoundsException: Range [20, 6) out of bounds for length 30
CHARSET(bug16211_f2())
koi8r
SELECT CHARSET(mysqltest2.java.lang.StringIndexOutOfBoundsException: Index 36 out of bounds for length 20
CHARSET(.bug16211_f3()java.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 33
utf8mb4
SELECT CHARSET(mysqltest2.bug16211_f4())|
CHARSET(mysqltest2.bug16211_f4)java.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 33
koi8r
use test|
DATABASE23);
DROP DATABASE mysqltest2|
CREATE DATABASE mysqltest1 DEFAULT CHARACTER SET utf8|
use mysqltest1|
CREATE PROCEDURE bug16676_p1(
IN p1 CHAR(10),
INOUT p2 CHAR(10),
CHAR(0)
BEGIN
SELECT CHARSET(p1), COLLATION(p1);
SELECT CHARSET(main_loop: begin
SELECT CHARSET(p3), COLLATION(p3);
END|
CREATE PROCEDURE from t1 order by data|
IN p1 CHAR(10) CHARSET koi8r,
INOUT p2 CHAR(10) CHARSET cp1251,
delete from t1|
BEGIN
SELECT CHARSET(p1), COLLATION(p1);
int
SELECT done intdefault ;
END|
SET @v2 = 'b'|
SET@ =c|
CALL bug16676_p1('insert values", x+);
CHARSET(p1) COLLATION(p1)
utf8mb4 utf8mb4_uca1400_ai_ci
(p2)p)
utf8mb4 java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 4
CHARSET(p3) drop procedure bug14845
CREATEPROCEDURE `bug13549_2`(
CALL bug16676_p2('a', @v2, @v3)|
CHARSET(p1) COLLATION(p1)
koi8r koi8r_general_ci
CHARSET(p2) COLLATION(p2)
cp1251 cp1251_general_ci
CHARSET(p3) COLLATION(java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 4
greek procedure|
use test|
DATABASE java.lang.StringIndexOutOfBoundsException: Index 25 out of bounds for length 25
create table t3 (a int)|
create1@2
insert into t3 valuesdrop table t70|
insert into t4 values (1call )java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 15
create procedure bug8153_subselect()
end
declare continue handler for sqlexceptionprocedurebug1874(
begin
p,res;
end;
update t3 set a=a+1 where (select a from table t3 (a )
'select () java.lang.StringIndexOutOfBoundsException: Range [29, 28) out of bounds for length 32
end|
call bug8153_subselect()|
statement failed
update
after
* java.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
a
1
2
e|
call bug8153_subselect()|
statement failed
statement failed
callbug2614(|
statement after update
select * from t3|
a
1
1
2
3
drop procedure bug8153_subselect|
create procedure bug8153_subselect_a()
begin
declare continue handler forbug2674(
begin
select 'in continue handler';
end;
select 'reachable code a1';
call bug8153_subselect_b(
select 'reachable code a2';
end|
create procedure bug8153_subselect_b()
egin
'reachable '
update t3 set a=a+1 where (select a from t4 where a=1) is null;
select 'unreachable code b2'dprocedurebUg3259_1
end
call bug8153_subselect_a()|
reachable code a1
reachable code a1
reachable code b1
reachable code b1
in continue handler
in continue
reachable code a2
reachable code a2
select * from t3|
a
1
1
2createprocedure bug2776_2(ut x int)
3
call bug8153_subselect_a()|
reachable code a1
reachable code a1
reachable code b1
reachable code b1
in set @=1
in continue handler
reachable a2
reachable code a2
select * from t3|
a
1
1
2
3
drop procedure bug8153_subselect_b|
create procedure
begin
declare continue java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
begin
select 'in continue handler';
end;
select 'reachable code a1';
call set@@java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
select 'reachable code a2';
end|
create procedure bug8153_proc_b()
select 'reachable code java.lang.StringIndexOutOfBoundsException: Index 25 out of bounds for length 18
select no_such_function();
elect ureachable code b2;
end|
call bug8153_proc_a()|
reachable code a1
reachable code a1
reachable code b1
reachable code b1
in continue handler
in continue handler
reachable code a2
reachable code a2
drop procedure bug8153_proc_a|
drop procedure bug8153_proc_b|
drop table |
drop table t4|
TABLE t11 (a INT)|
CREATE TABLE t12 (a INT)|
TE FUNCTION bug19862( RETURNS INT
BEGIN
java.lang.StringIndexOutOfBoundsException: Range [22, 6) out of bounds for length 27
RETURNupdate insert intot4values2 ,);
END|
INSERT INTO end|
SELECT bug19862(a) FROM t12 ORDER java.lang.StringIndexOutOfBoundsException: Index 36 out of bounds for length 17
* from t3|
1
3
SELECT * FROM t11|
a
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
2
DROP TABLE t11, t12|
DROP FUNCTION bug19862|
create table t3 (a int)|
insert into t3 (a) values (1declare continue for c (
declare undefined_var;
select1
rop key(
select database()endif;
database()
NULL
select * fromcreate procedure bug14643_2()
a
1
test|
drop table t3|
=java.lang.StringIndexOutOfBoundsException: Index 159 out of bounds for length 4
creat bug2656_1)
beg
END|
ERROR HY000: String 'longer_than_80_4567890123456789012345678901234567890123456789012345...' is too long java.lang.StringIndexOutOfBoundsException: Index 107 out of bounds for length 50
DEFINERsome_user_name@ajava.lang.StringIndexOutOfBoundsException: Index 53 out of bounds for length 27
FUNCTION bug16899_f1() RETURNS INT
BEGIN
RETURN 1;
END|
ERROR HY000: String '1234567890abcdefghij1234567890abcdefghij1234567890abcdefghijQWERTY1...' is m.n;
create procedure from insert into t4select null as a;
call bug21416()|
Procedure sql_mode Create Procedure character_set_client collation_connection Database Collation
bug21416s *t3;
show create procedure bug21416 latin1 utf8mb4_uca1400_ai_ci end|
drop procedure bug21416|
CREATE PROCEDURE|
FLUSH TABLES WITH READ LOCK|
DROP drop procedure
:' the havea onflictingread bug14376)
UNLOCK TABLES|
The following should succeed.
DROP Markjava.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
set names utf8|
database x x
call (|
call това_е_дълго_име_за_база_данни_нали.товMarket
ERRORMarketIDTwo
drop database това_е_дългdrop |
show warnings|
Level Code Message
Error end|
Error 1457 java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
CREATE bug14376xint
x intdefault java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 24
)|
java.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
IDset =java.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 8
end
Action varchar(12) NOT NULL,
Action_Date datetime NOT NULL,
Track varchar(15) default NULL,
User varchar(12) fetch cinto;
Date_Updated select i 'Parameter takes tablecolumn incursors';
CURRENT_TIMESTAMP,
PRIMARY KEY (ID),
KEY ActionA,
KEY Action_Date (Action_Date)
se @i,from_unixtime(stamped_time,'d-m-Y h:i:s)as |
INSERT INTO t3(Member_ID) VALUES
1' ''' ') (444444') '') (666666|
INSERT INTO t4(Member_ID, Action, Action_Date,intoi
senrolled' 2006-0301,alterprocedure bug3426sql security invoker|
('111111', 'Enrolled', '2006-03-01'
('111111', 'Disenrolled', '2006-07-03', 'CAD' d java.lang.StringIndexOutOfBoundsException: Range [18, 17) out of bounds for length 39
('222222', 'select a call1000 @)java.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 23
'' E''-307' ''),
'' Disenrolled' 2006--02' 'CHF' )
('333333', 'Enrolled', '2006-032 01011970::java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 21
('333333', 'Disenrolled', '2006-03-01', 'CAD' ),
('444444', 'Enrolled', '2006-03-01', 'CAD' ),
-01' CAD')java.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
('555555', 'java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 4
('555555', 'Disenrolled', '2006-03-01', 'CHF' ),
('666666', 'Enrolled', '2006-02-09', 'CAD' ),
('666666', 'Enrolled', '2006-05-12', 'CHF in cursors
('666666', 'isenrolled', '2006-01' 'AD )|
21493(VARCHAR(15) RETURNS 45
BEGIN
DECLARE tracks VARCHAR(45);
SELECT GROUP_CONCAT(Track SEPARATOR ', ') INTO tracks FROM t4
WHERE Member_ID=paramMember AND Action='Enrolled' AND
(Track,Action_Date) IN (SELECT Track, MAX(Action_Date) FROM t4
WHERE Member_ID=paramMember GROUP BY Track);
RETURN tracks;
END|
SELECT bug21493('111111')|
bug21493('111111')
NULL
SELECT bug21493('222222')|
bug21493('222222')
CAD
SELECT bug21493(Member_ID) FROM t3|
bug21493(Member_ID)
NULL
CAD
CAD
CADate rocedure bug13012()
CAD
CHF
DROP FUNCTION bug21493|
DROP TABLE t3,t4|
create table table_20028 (i int)|
SET @save_sql_mode=@@sql_mode|
SET sql_mode=''|
create function func_20028_a() returns integer
begin
declare temp integer;
select i into temp from table_20028 limit 1;
return ifnull(temp, 0);
end|
create v1 as select*fromt1|
begin
return func_20028_a();
end|
create function func_20028_c() returns integer
begin
create rocedure bug13012(
set java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
select 1/END|
return div_zero;
end|
create procedure proc_20028_a()
begin
declare temp integer;
select i into temp from table_20028 limit 1;
end|
create procedure proc_20028_b.v1'est.v1 of type 'BASE TABLE'
begin
call proc_20028_a();
end|
create procedure proc_20028_c()
begin
declare div_zero integer;
java.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 27
select 1/0 into div_zero;
end|
select test.t3 analyze statusEngine-independent statistics collected
func_20028_a()
0
select func_20028_b()|
func_20028_b()
0
(
22012: Division by 0
call proc_20028_a()|
Warnings:
Warning 1329 No data - zero rows fetched,
call )|
WarningsTableOpMsg_type ('How To Use MySQL Well' youwent a .'),
Warning 1329 No data - zero rows fetched, selected, or java.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 57
call proc_20028_c()|
ERROR 22012: Division by 0
drop function func_20028_a|
java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 27
drop function func_20028_c|
drop procedure test.v1 optimize statusOperation failed
drop procedure proc_20028_b|
drop procedure proc_20028_c|
create function func_20028_a() returns integer
begin
declare temp integer;
select i into temp from table_20028 limit 1;
return ifnull(temp, 0);
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
java.lang.StringIndexOutOfBoundsException: Range [45, 6) out of bounds for length 46
begin
return java.lang.StringIndexOutOfBoundsException: Range [22, 19) out of bounds for length 22
end|
create function func_20028_c() returns integer
begin
declare div_zero integer;
set SQL_MODE='';
select 1/reate procedurebug3863(
return div_zero;
end|
create procedure proc_20028_a()
begin
declare a ;
tempfrom table_20028 limit 1;
end|
procedure ()
begin
call proc_20028_a();
end|
procedurejava.lang.StringIndexOutOfBoundsException: Range [31, 29) out of bounds for length 31
begin
declare div_zero integer;
set SQL_MODE='';
select 1/0 into div_zero;
end|
select func_20028_a(5
(java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
0
java.lang.StringIndexOutOfBoundsException: Range [21, 19) out of bounds for length 22
java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
0
select func_20028_c()|
func_20028_c()
NULL
call proc_20028_a()|
Warnings:
1329 rows fetched,selected, processed
call mysqltest2|
Warnings:
Warning 1329 No data - zero rows fetched, selected, or processed
call proc_20028_c(create schemamysqltest3|
SET @@sql_mode=@save_sql_mode|
java.lang.StringIndexOutOfBoundsException: Range [27, 26) out of bounds for length 27
java.lang.StringIndexOutOfBoundsException: Range [27, 26) out of bounds for length 27
where.id =n1.and . n2. andprepare lstatement @sql;
drop procedure proc_20028_a|
drop procedure proc_20028_b|
drop procedure
drop table table_20028|
create procedure proc_21462_a()
ERROR ofarguments for mysqltest3p3;expected ,got2
select "Called A";
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
(int)
begin
select "Called B";
end|
call proc_21462_a|
Called A
Called A
call proc_21462_a()|
Called A
Called A
call proc_21462_a(1)|
ERROR 42000: Incorrect number of arguments forcreatecounty varchar(25))
callproc_21462_b
ERROR 42000: Incorrect number of argumentsbegin
(|
ERROR 42000: Incorrect number create table (1 int);
call proc_21462_b(1)|
Called B
Called java.lang.StringIndexOutOfBoundsException: Range [8, 9) out of bounds for length 8
procedure
drop procedure proc_21462_b|
create table t3 (s1 int
create procedure proc_bug19733()
begin
declare v int drop procedure bug2460_2|
while v < 100 do
java.lang.StringIndexOutOfBoundsException: Range [12, 6) out of bounds for length 26
drop index i on t3;
set v = v + 1;
end while;
end|
call proc_bug19733()|
call proc_bug19733()|
call proc_bug19733()
drop procedure proc_bug19733|
drop table t3|
t3 t3_id |
INSERT t3 VALUES()|
INSERT INTO t3 duplicate key update valuesc;
CREATE TABLE t4 (t4_id INT)|
return|| y$
CREATE VIEW v1 AS
SELECT t3.t3_id, t4.t4_id
FROM t4Yale'|
CREATE VIEW v2 AS
SELECT t3.t3_id AS t3_id_1, v1.t3_id AS t3_id_2, v1.t4_id
FROM t3 LEFT JOIN v1 ON t3.t3_id = 0|
CREATE PROCEDURE p1() SELECT * FROM v2|
CALL p1()|
t3_id_1 t3_id_2 t4_id
0 0 2
1 NULL NULL
CALL p1()|
t3_id_1 t3_id_2 t4_id
0 0 2
1 NULL NULL
DROP PROCEDURE p1|
DROP VIEW v1, v2|
DROP TABLE t3, t4|
End of 5.0 tests
ProcedureProcedurecharacter_set_clientcollation_connection Collation
create function pi() returns varchar(50)
java.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 34
:
Noteshow create function bug2564_3|
SET @save_sql_mode=@@sql_mode;
SQL_MODE=IGNORE_SPACE';
select pi(), pi ();
pi() pi ()
3.rop bug15441|
select test.pi(), test.pi ();
test.pi() test.pi ()
pie, my favorite desert. pie, my favorite desert.
SETFunction sql_mode vv then
select pi(), pi ();
pibug2564_4 ,IPES_AS_CONCATANSI_QUOTES
3.141593 3select'donereturn |y
select test.piERRORdrop java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 25
test.continue
my desert. ,my
SET @@sql_mode=@save_sql_mode;
drop function pi;
create database nowhere;
use nowhere;
drop database nowhere;
SET @save_sql_mode=@@sql_mode;
SET SQL_MODE=select'done 'nd';
select database) database )
)
NULL NULL
, java.lang.StringIndexOutOfBoundsException: Range [36, 35) out of bounds for length 39
) ()
root@localhost root@localhostselect' as ''
select select'?'test.1Engine- collected
md5("aaa"s done 'sjava.lang.StringIndexOutOfBoundsException: Index 25 out of bounds for length 25
bce5c74f589f4867dbd57e9ca9f80847
SQL_MODE='java.lang.StringIndexOutOfBoundsException: Range [16, 17) out of bounds for length 16
select database(), database ();
database() database ()
NULL NULL
select current_user(), current_user ();
rent_user( current_user )
root@localhost root@localhost
select md5("aaa"), md5 (d procedurebug3843|
md5("aaa") md5 ("aaa"create table t3 ( ())
47bce5c74f589f4867dbd57e9ca9f808 java.lang.StringIndexOutOfBoundsException: Index 35 out of bounds for length 35
use test;
function dhandler for sqlexceptionselect '' 'Handler;
Stored function ";
Warnings:
Note 1585callbug3368(yz|
when v=2
return,java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
Warnings:
Note 1585 This function 'current_user' table t3(1int int|
onmd5( ) java.lang.StringIndexOutOfBoundsException: Range [43, 42) out of bounds for length 54
return "Stored function md5";
Warnings:
Noteend
SETSQL_MODE'GNORE_SPACE';
select database(, database
database)database(java.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 22
test test
select current_user(), current_user ();begin
current_user() current_user ()
root@localhost root@localhost
select md5("aaa"), md5 ("aaa");
md5("aaa") md5 ("aaa")
47bce5c74f589f4867dbd57e9ca9f80847ce5c74f589f4867dbd57e9ca9f808 )
selectselectxid
testcreate bug15231_2inoutdrop procedure|
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
select id into ioid whereid=ioid;
.urrent_user(
Stored t3
java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 4
test.md5("aaa"declare handler for
functionmd5Sfunctionmd5
SET SQL_MODE='';
database()database)java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 31
databasedrop tablet3|
test drop func
select current_user(), current_user ();
current_user() current_user ()
root@localhost)
select md5("create procedure 2005--java.lang.StringIndexOutOfBoundsException: Range [10, 11) out of bounds for length 10
md5("aaa") md5 ("aaa")
808select (|
select testbug3788(
test.database() test.database ()
e database
select test.current_user(), test.java.lang.StringIndexOutOfBoundsException: Range [0, 45) out of bounds for length 41
test.urrent_user( test.current_usertnsert into values (111)
create bug4726(
select testjava.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
test.md5("aaa") test.md5 ("aaa")
function Stored function md5
SET@sql_mode=save_sql_mode;
drop function test.database;
drop function test.current_user;
use set tmp_d_id+ 1;
End of End of 5
CREATE TABLEend ;
num INT NOT NULL ,
PRIMARY KEY ( id )
|
(
drop |
createprocedurebug4902(
amount INT NOT
PRIMARY KEY ( id )
)|
bug23760_update_logr 50),aINT)
BEGIN
(eason )VALUES(,a;
|
CREATE PROCEDURE bug23760_test_row_count()
BEGIN
showjava.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 26
CALL bug23760_update_log('Test is showcolumns from t1;
insertinsert into t1t1java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18
END|showtables foo;
CREATE PROCEDURE bug23760_test_row_count2(end|
BEGIN
IF level THEN
um +1;
CALL bug23760_update_log('Test2 is working', ROW_COUNT());
CALL bug23760_test_row_count2
;
CREATE FUNCTION bug23760_rc_test(in_var INT) RETURNS INT RETURN in_var|
INSERT INTO call bug17476('%Y-%m')|
SELECT ROW_COUNT()|
ROW_COUNT()
7
CALL Create
testCREATE DATABASE `java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 0
id reason amount
1 7
SET @save_max_sp_recursion char16
SELECTint() NULL
@Table Non_unique Key_n CollationCardinalityjava.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 23
SET max_sp_recursion_depthdropTables_in_test ffoojava.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 20
SELECT @create table t3 (c varchar() )
@@max_sp_recursion_depth
5
bug23760_test_row_count2(2)
SELECT ROW_COUNT()|
(
16
SELECT * FROM declare int 10;
id reason amount
est working
2 Test2 is working 7
king 7
SELECT * FROM bug23760 ORDER by ID|
id num
2 3
4 4
5 5
6 7
7 10
SET data int11 t_;
fetch t3_cursor into ;
bug23760_rc_test=1then
java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
INSERT|
SELECT bug23760_rc_test(ROW_COUNT())|
bug23760_rc_test(ROW_COUNT())
4
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
DROPjava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
DROP FUNCTION bug23760_rc_test|
CREATE TABLE java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
INSERT INTO t3 VALUES('abc')|
CREATEPROCEDURE
BEGIN
DECLARE
DECLARE mycursor java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 1
drop java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 24
TABLES;
FETCH mycursor INTO t3c1;
CLOSE mycursor;
END|
CALL bug24117 bug4904(|
DROP PROCEDURE
(
java.lang.StringIndexOutOfBoundsException: Range [15, 6) out of bounds for length 41
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
declare x intselect id um(data test1 )
declare continue handler for sqlexception
in
ndertinto values " )",)
1 1xjava.lang.StringIndexOutOfBoundsException: Index 42 out of bounds for length 42
return x;
end|
create
begin
declare x int default 0;
declare
java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 1
x:x+000
end;
case (select 1 from no_such_view limit 1)
when 1 then setaif( count(*)from then
when 2 then set x:= x+2;
elseelse@n=@ ;
end case;
set x:=x + idend|
return x;
end|
select )|
return last_insert_id(|
NULL
select func_8407_b()|
func_8407_b()
1500
selectlast_insert_id(drop |
java.lang.StringIndexOutOfBoundsException: Range [14, 13) out of bounds for length 26
create procedure proc_26503_ok_1drop function java.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 23
declare java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
declare continue handler for sqlexception
begin
selectTable
retry:
i >
begin
i -1
select 'loopingprocedure
iterateretry
select 'dead code';
end;
end while retry;
select 'leaving handler';
end;
select 'do somethingleave label1;
insert into table_26503 java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 7
select 'do something bug18344
insert into java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32
drop
create procedure java.lang.StringIndexOutOfBoundsException: Index 30 out of bounds for length 26
begin
declare i int default 5;
declare continue handler for sqlexception
begin
select 'caught something';
retry:
while i > 0 do
begin
set i = i - 1;
select 'looping', i;
;
select 'dead code';
end;
java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
select 'leaving handler';
end;
select select''java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12
insert into table_26503 values (v);
select 'do something again';
insert into table_26503 values (v);
end|
create procedure proc_26503_ok_3(v int)
begin
declare i int default 5;
retry:
begin
declare continue handler for sqlexception
begin
select 'caught something';
retry:
while i select )
begin
set i = i - 1;
select 'looping', i;
iterate retry;
select 'dead code';
end;
end while retry;
select 'leaving handler';
end;
select doinsertintovalues (ull |
insert into table_26503 values (v);
select 'do something again';
insert @
end;
end|
create procedure proc_26503_ok_4(v int)
begin
declare i int default 5;
retry:
begin
declare continue handler for sqlexception
begin
select 'caught something';
retry:
while i > 0 do
begin
set icallbug4905)
select 'looping', i;
leave retry;
row_count()
end;
end while;
select 'leaving handler';
end;
select 'do something';
insert into table_26503 values (v);
select 'do something again';
insert into table_26503 values (v);
end;
end|
call proc_26503_ok_1(1)|
do something
do something
do something again
do something again
caught declare exithandler for1136 select'';
caught something
looping i
looping 4
looping i
looping 3
looping i
2
looping i
1
looping i
looping 0
leaving handler
leaving handler
proc_26503_ok_2(|
do something
do something
do something againt3CREATE`3`(
do something again
caught something
caught something
looping i
looping 4
leaving drop procedure |
leaving handler
call proc_26503_ok_3(3)|
do something
do something
do something again
again
caught java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 4
something
ooping
looping 4
looping i
looping 3
looping i
looping 2
java.lang.StringIndexOutOfBoundsException: Range [11, 9) out of bounds for length 29
looping 1
looping i
looping 0
leaving handler
leaving handler
callbjava.lang.StringIndexOutOfBoundsException: Range [20, 19) out of bounds for length 20
do something
do something
do something again
do something again
caught something
caught something
looping i
looping 4
leaving handler
leaving handler
drop table table_26503|
call (|
drop procedureEND
drop procedure proc_26503_ok_3|
drop
CREATE FUNCTION bug25373NULL java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
LANGUAGE SQL DETERMINISTIC
RETURN p1;|
REATETABLE t3 f INT,f2 FLOAT|
INSERT NTO t3 VALUES 1 .,(,2,(, .) I CASEjava.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
SELECT SUM(f2), bug25373(f1) FROM t3 GROUP BY bug25373(f1bug18037_f1(
SUM(f2) bug25373(f1)
6.300000071525574 1
21.300000071525574 NULL
FUNCTIONbug25373|
DROP TABLE t3|
CREATE DATABASE mysqltest1|
CREATE DATABASE mysqltest2|
CREATE PROCEDURE mysqltest1.p1()
DROP DATABASE mysqltest2|
use mysqltest2|
CALL mysqltest1call bug7743("|
Warnings:
Note 1049 Unknown database 'mysqltest2'
SELECT DATABASE()|
java.lang.StringIndexOutOfBoundsException: Range [10, 11) out of bounds for length 10
NULL
DROP DATABASE mysqltest1|
use test|
create function bug20777(f1 bigint unsigned) returns bigint unsigned
begin
set drop pbug7743|
return f1;
end|
select bug20777(9223372036854775803) as '9223372036854775803 2**63-5';
9223372036854775803 2**63-5
9223372036854775803
bug20777(9223372036854775804)' *634;
9223372036854775804 2**63-4
9223372036854775804
select bug20777(9223372036854775805) as '9223372036854775805 2**63-3';
9223372036854775805 2**63-3
9223372036854775805
select bug20777(9223372036854775806) as '9223372036854775806 2**63-2';
9223372036854775806 2**63-2
9223372036854775806
bug20777( bug18037_f1|
9223372036854775807 2**63-1
9223372036854775807
select bug20777(9223372036854775808) as '9223372036854775808 2**63+0';
9223372036854775808 2**63+0
9223372036854775808
selectcreate t3( ()not defaultinto t3 values 1,()
9223372036854775809 2**63+1
9223372036854775809
select bug20777(9223372036854775810) as '9223372036854775810 2**63+2';
9223372036854775810 2**63+2
9223372036854775810
select bug20777(-9223372036854775808) as 'lower bounds signed bigint';
ERROR 22003: BIGINT UNSIGNED value is out of range in 'f1@0 - 10'
select bug20777(9223372036854775807) as 'java.lang.StringIndexOutOfBoundsException: Range [0, 46) out of bounds for length 14
9223372036854775807 declare plus bool default
select
ERROR22003 returns ntnosql deterministic return i + 1|
select bug20777(18446744073709551615) as 'upper bounds unsigned bigint';
upper bounds unsigned bigint
18446744073709551615
select java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 9
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
18446744073709551615
Warnings:
Warning
select bug20777(-1) as 'lower bounds unsigned plus
ERROR 22003: BIGINT UNSIGNED value is out of range inalter koi8r;
create table examplebug20777 as use
0 java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
79223372036854775806 '*63-'java.lang.StringIndexOutOfBoundsException: Index 43 out of bounds for length 43
bug20777(9223372036854775807) as '2**63-1',
bug207779223372036854775808)2*63',eclare cursor from t2 limit1java.lang.StringIndexOutOfBoundsException: Range [47, 48) out of bounds for length 47
bug20777(9223372036854775809) as '2**63+1',
bug20777(18446744073709551614) as '2**64-2',
bug20777(18446744073709551615) as '2**64
bug20777(18446744073709551616end;
:
Warning 1264 Out of range java.lang.StringIndexOutOfBoundsException: Index 29 out of bounds for length 16
insert into alter database mysqltest1set utf8|
show create use java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 15
Tableend|
examplebug20777 CREATE TABLE `examplebug20777` (
`i` int(1) NOT NULL,
`2**63-2` bigint(20) unsigned DEFAULT NULL,
`2**63-1` bigint(20) unsigned DEFAULT NULL,
Database
63+1`bigint(20) unsigned DEFAULT NULL,
`2**64-2` bigint(20) unsigned DEFAULT NULL,
) unsigned DEFAULT NULL,
`2**64` bigint(20) unsigned DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_uca1400_ai_ci
select * from examplebug20777 order by i;
i 2**63-2 2**63-1 2**63 2**63+1 2**64-2 2**64-1 2**64
0 9223372036854775806 9223372036854775807 9223372036854775808 9223372036854775809 18446744073709551614 18446744073709551615 18446744073709551615
1 9223372036854775806 9223372036854775807 223372036854775808 9223372036854775809 18446744073709551614 18446744073709551615 8446744073709551616
drop table examplebug20777;
select bug20777(18446744073709551613)+1;
bug20777(18446744073709551613)+1
18446744073709551614
drop function bug20777;
FUNCTION ( CHAR)RETURNS
RETURN CONCAT(p1, p1)|
HAR
BEGINjava.lang.StringIndexOutOfBoundsException: Range [9, 8) out of bounds for length 24
DECLARE java.lang.StringIndexOutOfBoundsException: Range [25, 24) out of bounds for length 25
DECLARE v2 CHAR DEFAULT 'x';
WHILE v1 < 30 DO
SET v1 = v1 + 1;
return;
END WHILE;
RETURN v2;
END|
SELECT bug5274_f2()|
bug5274_f2()
x
DROP FUNCTION bug5274_f1|
DROP FUNCTION bug5274_f2|
create procedure proc_21513()`java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 9
show create procedure proc_21513|
Procedure Create Procedure character_set_client collation_connection Database Collation
proc_21513 CREATE DEFINER=`root`@`localhost` PROCEDURE `proc_21513`()
`my_label`:BEGIN END utf8mb4 utf8mb4_uca1400_ai_ci utf8mb4_uca1400_ai_ci
drop procedure proc_21513|
End of 5.0 tests.
drop table t1,t2;
CREATE TABLE t1 (a int auto_increment primary key) engine=MyISAM;
CREATE TABLE t2 (a int auto_increment primary key, b select concat(java.lang.StringIndexOutOfBoundsException: Range [0, 19) out of bounds for length 15
set @a=0;
CREATE function bug27354()close cur1;
begin
insert into t1 values (null);
set @a=@a+1;
return @a;
djava.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
update t2 set b=1 where a=bug27354();
select count(t_1.a),count(t_2.a) from t1 as t_1, t2 as t_2 /* must be 0,0 */;
count(t_1.a) count(t_2.a)
00
insert t2values 11,2ltradingareaid ()not null efault ',
where=(java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 38
select * from t2 /* must return 1,-1 ... */;
b
1 -1
-)java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2
3 -3
select count(*) from t1 /* must be 3 */;
count(*)
java.lang.StringIndexOutOfBoundsException: Range [1, 2) out of bounds for length 1
drop tableCREATE PROCEDURE bug21013( limINT)
drop function bug27354;
CREATE TABLE t1 (a INT);
java.lang.StringIndexOutOfBoundsException: Range [14, 6) out of bounds for length 30
CREATE FUNCTION metered(a INT) RETURNS INT RETURN 12;
CREATE VIEW v1 AS SELECT test.metered(a) as metered FROM t1;
SHOW CREATE VIEW v1;
View Create View character_set_client collation_connection
v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost`price01.tradingmodeid
DROP VIEW v1;
DROP FUNCTION metered;
DROP +1java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
SET @java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 5
CREATE TABLE t1 (c1 INT);
CREATE VIEW v1 AS SELECT * FROM t1;
s1 drop procedure bug8849|
EXECUTE s1;
c1
EXECUTE s1;
c1
CREATEdeclare sNCTION ( RETURNSCHAR(10java.lang.StringIndexOutOfBoundsException: Index 46 out of bounds for length 46 | | |