Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
7ba22428
Commit
7ba22428
authored
Oct 12, 2002
by
Sinisa@sinisa.nasamreza.org
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Two bug fixes
parent
3805a5ed
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
32 additions
and
3 deletions
+32
-3
Docs/manual.texi
Docs/manual.texi
+5
-0
mysql-test/r/multi_update.result
mysql-test/r/multi_update.result
+16
-0
mysql-test/t/multi_update.test
mysql-test/t/multi_update.test
+9
-1
sql/sql_delete.cc
sql/sql_delete.cc
+1
-1
sql/sql_update.cc
sql/sql_update.cc
+1
-1
No files found.
Docs/manual.texi
View file @
7ba22428
...
@@ -50797,6 +50797,11 @@ each individual 4.0.x release.
...
@@ -50797,6 +50797,11 @@ each individual 4.0.x release.
@appendixsubsec Changes in release 4.0.5
@appendixsubsec Changes in release 4.0.5
@itemize
@itemize
@item
@item
Fixed a bug in multi-table deletes when outer join is used on an empty
table, which get's first to be deleted
@item
Fixed a bug in multi-table updates when a single table is updated
@item
Updated source tree to be built using @code{automake 1.5} and
Updated source tree to be built using @code{automake 1.5} and
@code{libtool 1.4}.
@code{libtool 1.4}.
@item
@item
mysql-test/r/multi_update.result
View file @
7ba22428
...
@@ -135,3 +135,19 @@ ID ParId tst tst1
...
@@ -135,3 +135,19 @@ ID ParId tst tst1
2 2 MSSQL Microsoft
2 2 MSSQL Microsoft
3 3 ORACLE ORACLE
3 3 ORACLE ORACLE
drop table parent, child;
drop table parent, child;
drop table if exists t1, t2 ;
create table t1 (n numeric(10));
create table t2 (n numeric(10));
insert into t2 values (1),(2),(4),(8),(16),(32);
select * from t2 left outer join t1 using (n);
n n
1 NULL
2 NULL
4 NULL
8 NULL
16 NULL
32 NULL
delete t1,t2 from t2 left outer join t1 using (n);
select * from t2 left outer join t1 using (n);
n n
drop table if exists t1,t2 ;
mysql-test/t/multi_update.test
View file @
7ba22428
...
@@ -139,4 +139,12 @@ WHERE child.ParId = parent.Id;
...
@@ -139,4 +139,12 @@ WHERE child.ParId = parent.Id;
select
*
from
child
;
select
*
from
child
;
drop
table
parent
,
child
;
drop
table
parent
,
child
;
\ No newline at end of file
drop
table
if
exists
t1
,
t2
;
create
table
t1
(
n
numeric
(
10
));
create
table
t2
(
n
numeric
(
10
));
insert
into
t2
values
(
1
),(
2
),(
4
),(
8
),(
16
),(
32
);
select
*
from
t2
left
outer
join
t1
using
(
n
);
delete
t1
,
t2
from
t2
left
outer
join
t1
using
(
n
);
select
*
from
t2
left
outer
join
t1
using
(
n
);
drop
table
if
exists
t1
,
t2
;
sql/sql_delete.cc
View file @
7ba22428
...
@@ -329,7 +329,7 @@ bool multi_delete::send_data(List<Item> &values)
...
@@ -329,7 +329,7 @@ bool multi_delete::send_data(List<Item> &values)
table
->
status
|=
STATUS_DELETED
;
table
->
status
|=
STATUS_DELETED
;
if
(
!
(
error
=
table
->
file
->
delete_row
(
table
->
record
[
0
])))
if
(
!
(
error
=
table
->
file
->
delete_row
(
table
->
record
[
0
])))
deleted
++
;
deleted
++
;
else
else
if
(
!
table_being_deleted
->
next
)
{
{
table
->
file
->
print_error
(
error
,
MYF
(
0
));
table
->
file
->
print_error
(
error
,
MYF
(
0
));
DBUG_RETURN
(
1
);
DBUG_RETURN
(
1
);
...
...
sql/sql_update.cc
View file @
7ba22428
...
@@ -768,7 +768,7 @@ bool multi_update::send_eof()
...
@@ -768,7 +768,7 @@ bool multi_update::send_eof()
thd
->
proc_info
=
"updating the reference tables"
;
thd
->
proc_info
=
"updating the reference tables"
;
/* Does updates for the last n - 1 tables, returns 0 if ok */
/* Does updates for the last n - 1 tables, returns 0 if ok */
int
error
=
do_updates
(
false
)
;
/* do_updates returns 0 if success */
int
error
=
(
num_updated
>
1
)
?
do_updates
(
false
)
:
0
;
/* do_updates returns 0 if success */
/* reset used flags */
/* reset used flags */
#ifndef NOT_USED
#ifndef NOT_USED
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment