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
d4982247
Commit
d4982247
authored
Mar 26, 2007
by
tomas@whalegate.ndb.mysql.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb
into whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-single-user
parents
3d076ca0
c445baea
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
27 additions
and
31 deletions
+27
-31
sql/ha_ndbcluster.cc
sql/ha_ndbcluster.cc
+18
-8
storage/ndb/include/ndbapi/NdbRecAttr.hpp
storage/ndb/include/ndbapi/NdbRecAttr.hpp
+2
-5
storage/ndb/src/ndbapi/NdbRecAttr.cpp
storage/ndb/src/ndbapi/NdbRecAttr.cpp
+6
-17
storage/ndb/test/src/NDBT_Table.cpp
storage/ndb/test/src/NDBT_Table.cpp
+1
-1
No files found.
sql/ha_ndbcluster.cc
View file @
d4982247
...
@@ -733,10 +733,9 @@ int ha_ndbcluster::set_ndb_value(NdbOperation *ndb_op, Field *field,
...
@@ -733,10 +733,9 @@ int ha_ndbcluster::set_ndb_value(NdbOperation *ndb_op, Field *field,
DBUG_PRINT
(
"info"
,
(
"bit field"
));
DBUG_PRINT
(
"info"
,
(
"bit field"
));
DBUG_DUMP
(
"value"
,
(
char
*
)
&
bits
,
pack_len
);
DBUG_DUMP
(
"value"
,
(
char
*
)
&
bits
,
pack_len
);
#ifdef WORDS_BIGENDIAN
#ifdef WORDS_BIGENDIAN
if
(
pack_len
<
5
)
/* store lsw first */
{
bits
=
((
bits
>>
32
)
&
0x00000000FFFFFFFF
)
DBUG_RETURN
(
ndb_op
->
setValue
(
fieldnr
,
((
char
*
)
&
bits
)
+
4
)
!=
0
);
|
((
bits
<<
32
)
&
0xFFFFFFFF00000000
);
}
#endif
#endif
DBUG_RETURN
(
ndb_op
->
setValue
(
fieldnr
,
(
char
*
)
&
bits
)
!=
0
);
DBUG_RETURN
(
ndb_op
->
setValue
(
fieldnr
,
(
char
*
)
&
bits
)
!=
0
);
}
}
...
@@ -3155,10 +3154,21 @@ void ndb_unpack_record(TABLE *table, NdbValue *value,
...
@@ -3155,10 +3154,21 @@ void ndb_unpack_record(TABLE *table, NdbValue *value,
else
else
{
{
DBUG_PRINT
(
"info"
,
(
"bit field H'%.8X%.8X"
,
DBUG_PRINT
(
"info"
,
(
"bit field H'%.8X%.8X"
,
*
(
Uint32
*
)
(
*
value
).
rec
->
aRef
(),
*
(
Uint32
*
)(
*
value
).
rec
->
aRef
(),
*
((
Uint32
*
)
(
*
value
).
rec
->
aRef
()
+
1
)));
*
((
Uint32
*
)(
*
value
).
rec
->
aRef
()
+
1
)));
field_bit
->
Field_bit
::
store
((
longlong
)
(
*
value
).
rec
->
u_64_value
(),
#ifdef WORDS_BIGENDIAN
/* lsw is stored first */
Uint32
*
buf
=
(
Uint32
*
)(
*
value
).
rec
->
aRef
();
((
Field_bit
*
)
*
field
)
->
store
((((
longlong
)
*
buf
)
&
0x000000000FFFFFFFF
)
|
((((
longlong
)
*
(
buf
+
1
))
<<
32
)
&
0xFFFFFFFF00000000
),
TRUE
);
TRUE
);
#else
((
Field_bit
*
)
*
field
)
->
store
((
longlong
)
(
*
value
).
rec
->
u_64_value
(),
TRUE
);
#endif
}
}
/*
/*
Move back internal field pointer to point to original
Move back internal field pointer to point to original
...
...
storage/ndb/include/ndbapi/NdbRecAttr.hpp
View file @
d4982247
...
@@ -305,10 +305,7 @@ inline
...
@@ -305,10 +305,7 @@ inline
Int32
Int32
NdbRecAttr
::
medium_value
()
const
NdbRecAttr
::
medium_value
()
const
{
{
Uint32
tmp
=
*
(
Uint32
*
)
theRef
;
return
sint3korr
((
unsigned
char
*
)
theRef
);
if
(
tmp
&
(
0x1
<<
23
))
tmp
|=
(
0xFF
<<
24
);
return
(
Int32
)
tmp
;
}
}
inline
inline
...
@@ -336,7 +333,7 @@ inline
...
@@ -336,7 +333,7 @@ inline
Uint32
Uint32
NdbRecAttr
::
u_medium_value
()
const
NdbRecAttr
::
u_medium_value
()
const
{
{
return
*
(
Uint32
*
)
theRef
;
return
uint3korr
((
unsigned
char
*
)
theRef
)
;
}
}
inline
inline
...
...
storage/ndb/src/ndbapi/NdbRecAttr.cpp
View file @
d4982247
...
@@ -234,24 +234,13 @@ ndbrecattr_print_formatted(NdbOut& out, const NdbRecAttr &r,
...
@@ -234,24 +234,13 @@ ndbrecattr_print_formatted(NdbOut& out, const NdbRecAttr &r,
break
;
break
;
case
NdbDictionary
:
:
Column
::
Bit
:
case
NdbDictionary
:
:
Column
::
Bit
:
out
<<
f
.
hex_prefix
<<
"0x"
;
out
<<
f
.
hex_prefix
<<
"0x"
;
if
(
length
<
33
)
{
{
out
.
print
(
"%X"
,
r
.
u_32_value
());
const
Uint32
*
buf
=
(
Uint32
*
)
r
.
aRef
();
}
int
k
=
(
length
+
31
)
/
32
;
else
if
(
length
<
65
)
while
(
k
>
0
&&
(
buf
[
--
k
]
==
0
));
{
out
.
print
(
"%X"
,
buf
[
k
]);
out
.
print
(
"%llX"
,
r
.
u_64_value
());
while
(
k
>
0
)
}
out
.
print
(
"%.8X"
,
buf
[
--
k
]);
else
{
const
unsigned
char
*
buf
=
(
unsigned
char
*
)
r
.
aRef
();
int
k
=
4
*
((
length
+
31
)
/
32
);
while
(
k
>
0
&&
(
*
(
buf
+
--
k
)
==
0
));
do
{
out
.
print
(
"%X"
,
(
Uint32
)
*
(
buf
+
k
--
));
}
while
(
k
>=
0
);
}
}
break
;
break
;
case
NdbDictionary
:
:
Column
::
Unsigned
:
case
NdbDictionary
:
:
Column
::
Unsigned
:
...
...
storage/ndb/test/src/NDBT_Table.cpp
View file @
d4982247
...
@@ -33,7 +33,7 @@ operator <<(class NdbOut& ndbout, const NDBT_Table & tab)
...
@@ -33,7 +33,7 @@ operator <<(class NdbOut& ndbout, const NDBT_Table & tab)
ndbout
<<
"Length of frm data: "
<<
tab
.
getFrmLength
()
<<
endl
;
ndbout
<<
"Length of frm data: "
<<
tab
.
getFrmLength
()
<<
endl
;
ndbout
<<
"Row Checksum: "
<<
tab
.
getRowChecksumIndicator
()
<<
endl
;
ndbout
<<
"Row Checksum: "
<<
tab
.
getRowChecksumIndicator
()
<<
endl
;
ndbout
<<
"Row GCI: "
<<
tab
.
getRowGCIIndicator
()
<<
endl
;
ndbout
<<
"Row GCI: "
<<
tab
.
getRowGCIIndicator
()
<<
endl
;
ndbout
<<
"SingleUserMode: "
<<
tab
.
getSingleUserMode
()
<<
endl
;
ndbout
<<
"SingleUserMode: "
<<
(
Uint32
)
tab
.
getSingleUserMode
()
<<
endl
;
//<< ((tab.getTupleKey() == TupleId) ? " tupleid" : "") <<endl;
//<< ((tab.getTupleKey() == TupleId) ? " tupleid" : "") <<endl;
ndbout
<<
"TableStatus: "
;
ndbout
<<
"TableStatus: "
;
...
...
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