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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
368731a9
Commit
368731a9
authored
Feb 10, 2002
by
monty@hundin.mysql.fi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed bug in full join with many NULL fields.
parent
2abdcf81
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
47 additions
and
8 deletions
+47
-8
Build-tools/Do-compile
Build-tools/Do-compile
+5
-2
Docs/manual.texi
Docs/manual.texi
+10
-1
mysql-test/r/join.result
mysql-test/r/join.result
+3
-0
mysql-test/t/join.test
mysql-test/t/join.test
+24
-0
sql/sql_select.cc
sql/sql_select.cc
+5
-5
No files found.
Build-tools/Do-compile
View file @
368731a9
...
...
@@ -108,7 +108,7 @@ $|=1;
select
STDOUT
;
$|
=
1
;
safe_cd
(
"
$host
"
);
safe_cd
(
$host
);
if
(
$opt_stage
==
0
&&
!
$opt_use_old_distribution
)
{
safe_system
("
gunzip <
$opt_distribution
|
$tar
xf -
");
...
...
@@ -118,6 +118,7 @@ if ($opt_stage == 0 && ! $opt_use_old_distribution)
system
("
touch timestamp; find . -newer timestamp -print | xargs touch; rm -f timestamp
");
sleep
(
2
);
# Ensure that files we don't want to rebuild are newer than other files
safe_cd
(
$ver
);
foreach
$name
("
configure
",
"
Docs/include.texi
",
"
Docs/*.html
",
"
Docs/manual.txt
",
"
Docs/mysql.info
",
...
...
@@ -125,9 +126,11 @@ if ($opt_stage == 0 && ! $opt_use_old_distribution)
{
system
("
touch
$name
");
}
# Fix some file modes in BDB tables that makes life harder.
system
("
chmod -R u+rw .
");
}
safe_cd
(
$ver
);
safe_cd
(
"
$pwd
/
$host
/
$ver
"
);
if
(
$opt_stage
<=
1
)
{
$opt_config_options
.=
"
--with-low-memory
"
if
(
$opt_with_low_memory
);
...
...
Docs/manual.texi
View file @
368731a9
...
...
@@ -46833,6 +46833,7 @@ users use this code as the rest of the code and because of this we are
not yet 100% confident in this code.
@menu
* News-3.23.49::
* News-3.23.48:: Changes in release 3.23.48
* News-3.23.47:: Changes in release 3.23.47
* News-3.23.46:: Changes in release 3.23.46
...
...
@@ -46885,7 +46886,15 @@ not yet 100% confident in this code.
* News-3.23.0:: Changes in release 3.23.0
@end menu
@node News-3.23.48, News-3.23.47, News-3.23.x, News-3.23.x
@node News-3.23.49, News-3.23.48, News-3.23.x, News-3.23.x
@appendixsubsec Changes in release 3.23.49
@itemize @bullet
@item
Fixed unlikely caching bug when doing a join without keys. In this case
the last used field for a table always returned @code{NULL}.
@end itemize
@node News-3.23.48, News-3.23.47, News-3.23.49, News-3.23.x
@appendixsubsec Changes in release 3.23.48
@itemize @bullet
@item
mysql-test/r/join.result
View file @
368731a9
...
...
@@ -31,3 +31,6 @@ COUNT(t1.Title)
1
COUNT(t1.Title)
1
t1_id t2_id type cost_unit min_value max_value t3_id item_id id name
22 1 Percent Cost 100 -1 6 291 1 s1
23 1 Percent Cost 100 -1 21 291 1 s1
mysql-test/t/join.test
View file @
368731a9
...
...
@@ -194,3 +194,27 @@ t3.Contractor_ID = '999999' OR
t3
.
Contractor_ID
=
'1'
)
AND
t3
.
CanRead
=
'1'
AND
t3
.
Active
=
'1'
;
drop
table
t1
,
t2
,
t3
;
#
# Bug when doing full join and NULL fields.
#
CREATE
TABLE
t1
(
t1_id
int
(
11
)
default
NULL
,
t2_id
int
(
11
)
default
NULL
,
type
enum
(
'Cost'
,
'Percent'
)
default
NULL
,
cost_unit
enum
(
'Cost'
,
'Unit'
)
default
NULL
,
min_value
double
default
NULL
,
max_value
double
default
NULL
,
t3_id
int
(
11
)
default
NULL
,
item_id
int
(
11
)
default
NULL
)
TYPE
=
MyISAM
;
INSERT
INTO
t1
VALUES
(
12
,
5
,
'Percent'
,
'Cost'
,
-
1
,
0
,
-
1
,
-
1
),(
14
,
4
,
'Percent'
,
'Cost'
,
-
1
,
0
,
-
1
,
-
1
),(
18
,
5
,
'Percent'
,
'Cost'
,
-
1
,
0
,
-
1
,
-
1
),(
19
,
4
,
'Percent'
,
'Cost'
,
-
1
,
0
,
-
1
,
-
1
),(
20
,
5
,
'Percent'
,
'Cost'
,
100
,
-
1
,
22
,
291
),(
21
,
5
,
'Percent'
,
'Cost'
,
100
,
-
1
,
18
,
291
),(
22
,
1
,
'Percent'
,
'Cost'
,
100
,
-
1
,
6
,
291
),(
23
,
1
,
'Percent'
,
'Cost'
,
100
,
-
1
,
21
,
291
),(
24
,
1
,
'Percent'
,
'Cost'
,
100
,
-
1
,
9
,
291
),(
25
,
1
,
'Percent'
,
'Cost'
,
100
,
-
1
,
4
,
291
),(
26
,
1
,
'Percent'
,
'Cost'
,
100
,
-
1
,
20
,
291
),(
27
,
4
,
'Percent'
,
'Cost'
,
100
,
-
1
,
7
,
202
),(
28
,
1
,
'Percent'
,
'Cost'
,
50
,
-
1
,
-
1
,
137
),(
29
,
2
,
'Percent'
,
'Cost'
,
100
,
-
1
,
4
,
354
),(
30
,
2
,
'Percent'
,
'Cost'
,
100
,
-
1
,
9
,
137
),(
93
,
2
,
'Cost'
,
'Cost'
,
-
1
,
10000000
,
-
1
,
-
1
);
CREATE
TABLE
t2
(
id
int
(
10
)
unsigned
NOT
NULL
auto_increment
,
name
varchar
(
255
)
default
NULL
,
PRIMARY
KEY
(
id
)
)
TYPE
=
MyISAM
;
INSERT
INTO
t2
VALUES
(
1
,
's1'
),(
2
,
's2'
),(
3
,
's3'
),(
4
,
's4'
),(
5
,
's5'
);
select
t1
.*
,
t2
.*
from
t1
,
t2
where
t2
.
id
=
t1
.
t2_id
limit
2
;
drop
table
t1
,
t2
;
sql/sql_select.cc
View file @
368731a9
...
...
@@ -5636,10 +5636,10 @@ SORT_FIELD *make_unireg_sortorder(ORDER *order, uint *length)
/*****************************************************************************
**
Fill join cache with packed records
**
Records are stored in tab->cache.buffer and last record in
**
last record is stored with pointers to blobs to support very big
**
records
Fill join cache with packed records
Records are stored in tab->cache.buffer and last record in
last record is stored with pointers to blobs to support very big
records
******************************************************************************/
static
int
...
...
@@ -5701,7 +5701,7 @@ join_init_cache(THD *thd,JOIN_TAB *tables,uint table_count)
if
(
null_fields
&&
tables
[
i
].
table
->
null_fields
)
{
/* must copy null bits */
copy
->
str
=
(
char
*
)
tables
[
i
].
table
->
null_flags
;
copy
->
length
=
(
tables
[
i
].
table
->
null_fields
+
7
)
/
8
;
copy
->
length
=
tables
[
i
].
table
->
null_bytes
;
copy
->
strip
=
0
;
copy
->
blob_field
=
0
;
length
+=
copy
->
length
;
...
...
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