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
e6510c89
Commit
e6510c89
authored
Jan 14, 2005
by
ram@gw.mysql.r18.ru
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
A fix for bit type.
pack_length_in_rec() func has been introduced.
parent
de6af317
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
1 deletion
+3
-1
sql/field.h
sql/field.h
+2
-0
sql/ha_myisam.cc
sql/ha_myisam.cc
+1
-1
No files found.
sql/field.h
View file @
e6510c89
...
...
@@ -123,6 +123,7 @@ public:
}
virtual
bool
eq_def
(
Field
*
field
);
virtual
uint32
pack_length
()
const
{
return
(
uint32
)
field_length
;
}
virtual
uint32
pack_length_in_rec
()
const
{
return
pack_length
();
}
virtual
void
reset
(
void
)
{
bzero
(
ptr
,
pack_length
());
}
virtual
void
reset_fields
()
{}
virtual
void
set_default
()
...
...
@@ -1237,6 +1238,7 @@ public:
{
get_key_image
(
buff
,
length
,
itRAW
);
}
uint32
pack_length
()
const
{
return
(
uint32
)
field_length
+
(
bit_len
>
0
);
}
uint32
pack_length_in_rec
()
const
{
return
field_length
;
}
void
sql_type
(
String
&
str
)
const
;
field_cast_enum
field_cast_type
()
{
return
FIELD_CAST_BIT
;
}
char
*
pack
(
char
*
to
,
const
char
*
from
,
uint
max_length
=~
(
uint
)
0
);
...
...
sql/ha_myisam.cc
View file @
e6510c89
...
...
@@ -1467,7 +1467,7 @@ int ha_myisam::create(const char *name, register TABLE *table_arg,
fieldpos
<=
minpos
)
{
/* skip null fields */
if
(
!
(
temp_length
=
(
*
field
)
->
pack_length
()))
if
(
!
(
temp_length
=
(
*
field
)
->
pack_length
_in_rec
()))
continue
;
/* Skip null-fields */
if
(
!
found
||
fieldpos
<
minpos
||
(
fieldpos
==
minpos
&&
temp_length
<
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