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
e8bb0c92
Commit
e8bb0c92
authored
Aug 23, 2006
by
unknown
Browse files
Options
Browse Files
Download
Plain Diff
Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into moonbone.local:/work/21475-fix-5.0-opt-mysql
parents
bbda4dd3
d8c9de79
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
20 additions
and
2 deletions
+20
-2
sql/item.cc
sql/item.cc
+5
-2
sql/item_cmpfunc.cc
sql/item_cmpfunc.cc
+1
-0
sql/item_func.cc
sql/item_func.cc
+13
-0
sql/item_func.h
sql/item_func.h
+1
-0
No files found.
sql/item.cc
View file @
e8bb0c92
...
...
@@ -305,6 +305,7 @@ Item::Item():
maybe_null
=
null_value
=
with_sum_func
=
unsigned_flag
=
0
;
decimals
=
0
;
max_length
=
0
;
with_subselect
=
0
;
cmp_context
=
(
Item_result
)
-
1
;
/* Put item in free list so that we can free all items at end */
THD
*
thd
=
current_thd
;
...
...
@@ -343,7 +344,8 @@ Item::Item(THD *thd, Item *item):
unsigned_flag
(
item
->
unsigned_flag
),
with_sum_func
(
item
->
with_sum_func
),
fixed
(
item
->
fixed
),
collation
(
item
->
collation
)
collation
(
item
->
collation
),
cmp_context
(
item
->
cmp_context
)
{
next
=
thd
->
free_list
;
// Put in free list
thd
->
free_list
=
this
;
...
...
@@ -3788,7 +3790,8 @@ Item *Item_field::equal_fields_propagator(byte *arg)
The same problem occurs when comparing a DATE/TIME field with a
DATE/TIME represented as an int and as a string.
*/
if
(
!
item
||
item
->
cmp_context
!=
cmp_context
)
if
(
!
item
||
(
cmp_context
!=
(
Item_result
)
-
1
&&
item
->
cmp_context
!=
cmp_context
))
item
=
this
;
return
item
;
}
...
...
sql/item_cmpfunc.cc
View file @
e8bb0c92
...
...
@@ -1220,6 +1220,7 @@ void Item_func_between::fix_length_and_dec()
if
(
!
args
[
0
]
||
!
args
[
1
]
||
!
args
[
2
])
return
;
agg_cmp_type
(
thd
,
&
cmp_type
,
args
,
3
);
args
[
0
]
->
cmp_context
=
args
[
1
]
->
cmp_context
=
args
[
2
]
->
cmp_context
=
cmp_type
;
if
(
cmp_type
==
STRING_RESULT
)
agg_arg_charsets
(
cmp_collation
,
args
,
3
,
MY_COLL_CMP_CONV
,
1
);
...
...
sql/item_func.cc
View file @
e8bb0c92
...
...
@@ -3897,6 +3897,19 @@ bool Item_func_set_user_var::send(Protocol *protocol, String *str_arg)
return
Item
::
send
(
protocol
,
str_arg
);
}
void
Item_func_set_user_var
::
make_field
(
Send_field
*
tmp_field
)
{
if
(
result_field
)
{
result_field
->
make_field
(
tmp_field
);
DBUG_ASSERT
(
tmp_field
->
table_name
!=
0
);
if
(
Item
::
name
)
tmp_field
->
col_name
=
Item
::
name
;
// Use user supplied name
}
else
Item
::
make_field
(
tmp_field
);
}
String
*
Item_func_get_user_var
::
val_str
(
String
*
str
)
{
...
...
sql/item_func.h
View file @
e8bb0c92
...
...
@@ -1175,6 +1175,7 @@ class Item_func_set_user_var :public Item_func
bool
update_hash
(
void
*
ptr
,
uint
length
,
enum
Item_result
type
,
CHARSET_INFO
*
cs
,
Derivation
dv
,
bool
unsigned_arg
=
0
);
bool
send
(
Protocol
*
protocol
,
String
*
str_arg
);
void
make_field
(
Send_field
*
tmp_field
);
bool
check
(
bool
use_result_field
);
bool
update
();
enum
Item_result
result_type
()
const
{
return
cached_result_type
;
}
...
...
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