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
66e8439d
Commit
66e8439d
authored
Sep 14, 2013
by
Andrew McDonnell
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
More test suite cleanups.
parent
aece0e40
Changes
8
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
496 additions
and
29 deletions
+496
-29
mysql-test/suite/oqgraph/boundary_conditions.result
mysql-test/suite/oqgraph/boundary_conditions.result
+54
-7
mysql-test/suite/oqgraph/boundary_conditions.test
mysql-test/suite/oqgraph/boundary_conditions.test
+17
-15
mysql-test/suite/oqgraph/create_attr.result
mysql-test/suite/oqgraph/create_attr.result
+3
-3
mysql-test/suite/oqgraph/create_attr_legacy.result
mysql-test/suite/oqgraph/create_attr_legacy.result
+150
-0
mysql-test/suite/oqgraph/create_attr_legacy.test
mysql-test/suite/oqgraph/create_attr_legacy.test
+202
-0
mysql-test/suite/oqgraph/regression_drop_after.result
mysql-test/suite/oqgraph/regression_drop_after.result
+28
-0
mysql-test/suite/oqgraph/regression_drop_after.test
mysql-test/suite/oqgraph/regression_drop_after.test
+38
-0
storage/oqgraph/ha_oqgraph.cc
storage/oqgraph/ha_oqgraph.cc
+4
-4
No files found.
mysql-test/suite/oqgraph/boundary_conditions.result
View file @
66e8439d
...
...
@@ -45,7 +45,7 @@ SELECT * FROM graph WHERE latch=0 and destid=1;
latch origid destid weight seq linkid
SELECT * FROM graph WHERE latch=0 and origid=666;
latch origid destid weight seq linkid
SELECT * FROM graph WHERE latch=0 and origid
=
NULL;
SELECT * FROM graph WHERE latch=0 and origid
is
NULL;
latch origid destid weight seq linkid
SELECT * FROM graph WHERE latch=1 ;
latch origid destid weight seq linkid
...
...
@@ -57,7 +57,7 @@ SELECT * FROM graph WHERE latch=1 and destid=1;
latch origid destid weight seq linkid
SELECT * FROM graph WHERE latch=1 and origid=666;
latch origid destid weight seq linkid
SELECT * FROM graph WHERE latch=1 and origid
=
NULL;
SELECT * FROM graph WHERE latch=1 and origid
is
NULL;
latch origid destid weight seq linkid
SELECT * FROM graph WHERE latch=2 ;
latch origid destid weight seq linkid
...
...
@@ -69,7 +69,7 @@ SELECT * FROM graph WHERE latch=2 and destid=1;
latch origid destid weight seq linkid
SELECT * FROM graph WHERE latch=2 and origid=666;
latch origid destid weight seq linkid
SELECT * FROM graph WHERE latch=2 and origid
=
NULL;
SELECT * FROM graph WHERE latch=2 and origid
is
NULL;
latch origid destid weight seq linkid
# Should this return an error? it seems we treat it as just another bogus latch
SELECT * FROM graph WHERE latch='ThisExceeds32Characters456789012';
...
...
@@ -93,8 +93,10 @@ SELECT * FROM graph WHERE latch='bogus' and origid=666;
latch origid destid weight seq linkid
Warnings:
Warning 1210 Incorrect arguments to OQGRAPH latch
SELECT * FROM graph WHERE latch='bogus' and origid
=
NULL;
SELECT * FROM graph WHERE latch='bogus' and origid
is
NULL;
latch origid destid weight seq linkid
Warnings:
Warning 1210 Incorrect arguments to OQGRAPH latch
SELECT * FROM graph WHERE latch='666';
latch origid destid weight seq linkid
SELECT * FROM graph WHERE latch='666' and destid=2 and origid=1;
...
...
@@ -113,8 +115,10 @@ SELECT * FROM graph WHERE latch='666' and origid=666;
latch origid destid weight seq linkid
Warnings:
Warning 1210 Incorrect arguments to OQGRAPH latch
SELECT * FROM graph WHERE latch='666' and origid
=
NULL;
SELECT * FROM graph WHERE latch='666' and origid
is
NULL;
latch origid destid weight seq linkid
Warnings:
Warning 1210 Incorrect arguments to OQGRAPH latch
SELECT * FROM graph WHERE latch='-1';
latch origid destid weight seq linkid
SELECT * FROM graph WHERE latch='-1' and destid=2 and origid=1;
...
...
@@ -133,8 +137,10 @@ SELECT * FROM graph WHERE latch='-1' and origid=666;
latch origid destid weight seq linkid
Warnings:
Warning 1210 Incorrect arguments to OQGRAPH latch
SELECT * FROM graph WHERE latch='-1' and origid
=
NULL;
SELECT * FROM graph WHERE latch='-1' and origid
is
NULL;
latch origid destid weight seq linkid
Warnings:
Warning 1210 Incorrect arguments to OQGRAPH latch
# Make sure we dont crash if someone passed in a UTF string
SELECT * FROM graph WHERE latch='Ω Ohms Tennis Ball 〄';
latch origid destid weight seq linkid
...
...
@@ -154,14 +160,55 @@ SELECT * FROM graph WHERE latch='Ω Ohms Tennis Ball 〄' and origid=666;
latch origid destid weight seq linkid
Warnings:
Warning 1210 Incorrect arguments to OQGRAPH latch
SELECT * FROM graph WHERE latch='Ω Ohms Tennis Ball 〄' and origid=NULL;
SELECT * FROM graph WHERE latch='Ω Ohms Tennis Ball 〄' and origid is NULL;
latch origid destid weight seq linkid
Warnings:
Warning 1210 Incorrect arguments to OQGRAPH latch
# Return all edges when latch is NULL
SELECT * FROM graph WHERE latch is NULL;
latch origid destid weight seq linkid
NULL 1 2 1 NULL NULL
NULL 2 1 1 NULL NULL
NULL 1 3 1 NULL NULL
NULL 3 1 1 NULL NULL
NULL 3 4 1 NULL NULL
NULL 4 3 1 NULL NULL
NULL 5 6 1 NULL NULL
NULL 6 5 1 NULL NULL
SELECT * FROM graph WHERE latch is NULL and destid=2 and origid=1;
latch origid destid weight seq linkid
NULL 1 2 1 3 1
NULL 1 2 1 2 3
NULL 1 2 1 1 2
SELECT * FROM graph WHERE latch is NULL and origid=1;
latch origid destid weight seq linkid
NULL 1 NULL 1 2 3
NULL 1 NULL 1 1 2
SELECT * FROM graph WHERE latch is NULL and destid=1;
latch origid destid weight seq linkid
NULL NULL 1 1 2 3
NULL NULL 1 1 1 2
SELECT * FROM graph WHERE latch is NULL and origid=666;
latch origid destid weight seq linkid
SELECT * FROM graph WHERE latch is NULL and origid is NULL;
latch origid destid weight seq linkid
NULL NULL NULL NULL NULL 1
NULL NULL NULL NULL NULL 2
NULL NULL NULL NULL NULL 3
NULL NULL NULL NULL NULL 4
NULL NULL NULL NULL NULL 5
NULL NULL NULL NULL NULL 6
INSERT INTO graph_base(from_id, to_id) VALUES (1,2);
ERROR 23000: Duplicate entry '1-2' for key 'PRIMARY'
DELETE FROM graph_base;
SELECT * FROM graph;
latch origid destid weight seq linkid
FLUSH TABLES;
TRUNCATE TABLE graph_base;
SELECT * FROM graph;
latch origid destid weight seq linkid
DROP TABLE graph_base;
FLUSH TABLES;
SELECT * FROM graph WHERE latch='dijkstras' AND origid=1 AND destid=6;
ERROR 42S02: Table 'test.graph_base' doesn't exist
DROP TABLE graph;
mysql-test/suite/oqgraph/boundary_conditions.test
View file @
66e8439d
...
...
@@ -51,19 +51,19 @@ SELECT * FROM graph WHERE latch=0 and destid=2 and origid=1;
SELECT
*
FROM
graph
WHERE
latch
=
0
and
origid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
0
and
destid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
0
and
origid
=
666
;
SELECT
*
FROM
graph
WHERE
latch
=
0
and
origid
=
NULL
;
SELECT
*
FROM
graph
WHERE
latch
=
0
and
origid
is
NULL
;
SELECT
*
FROM
graph
WHERE
latch
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
1
and
destid
=
2
and
origid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
1
and
origid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
1
and
destid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
1
and
origid
=
666
;
SELECT
*
FROM
graph
WHERE
latch
=
1
and
origid
=
NULL
;
SELECT
*
FROM
graph
WHERE
latch
=
1
and
origid
is
NULL
;
SELECT
*
FROM
graph
WHERE
latch
=
2
;
SELECT
*
FROM
graph
WHERE
latch
=
2
and
destid
=
2
and
origid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
2
and
origid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
2
and
destid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
2
and
origid
=
666
;
SELECT
*
FROM
graph
WHERE
latch
=
2
and
origid
=
NULL
;
SELECT
*
FROM
graph
WHERE
latch
=
2
and
origid
is
NULL
;
--
echo
# Should this return an error? it seems we treat it as just another bogus latch
SELECT
*
FROM
graph
WHERE
latch
=
'ThisExceeds32Characters456789012'
;
...
...
@@ -73,7 +73,7 @@ SELECT * FROM graph WHERE latch='bogus' and destid=2 and origid=1;
SELECT
*
FROM
graph
WHERE
latch
=
'bogus'
and
origid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
'bogus'
and
destid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
'bogus'
and
origid
=
666
;
SELECT
*
FROM
graph
WHERE
latch
=
'bogus'
and
origid
=
NULL
;
SELECT
*
FROM
graph
WHERE
latch
=
'bogus'
and
origid
is
NULL
;
#-- Note the next line couter-intuitively produces no warning
SELECT
*
FROM
graph
WHERE
latch
=
'666'
;
SELECT
*
FROM
graph
WHERE
latch
=
'666'
and
destid
=
2
and
origid
=
1
;
...
...
@@ -81,13 +81,13 @@ SELECT * FROM graph WHERE latch='666' and origid=1;
SELECT
*
FROM
graph
WHERE
latch
=
'666'
and
destid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
'666'
and
origid
=
666
;
#-- Note the next line couter-intuitively produces no warning
SELECT
*
FROM
graph
WHERE
latch
=
'666'
and
origid
=
NULL
;
SELECT
*
FROM
graph
WHERE
latch
=
'666'
and
origid
is
NULL
;
SELECT
*
FROM
graph
WHERE
latch
=
'-1'
;
SELECT
*
FROM
graph
WHERE
latch
=
'-1'
and
destid
=
2
and
origid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
'-1'
and
origid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
'-1'
and
destid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
'-1'
and
origid
=
666
;
SELECT
*
FROM
graph
WHERE
latch
=
'-1'
and
origid
=
NULL
;
SELECT
*
FROM
graph
WHERE
latch
=
'-1'
and
origid
is
NULL
;
--
echo
# Make sure we dont crash if someone passed in a UTF string
#-- Note the next line couter-intuitively produces no warning
...
...
@@ -97,18 +97,19 @@ SELECT * FROM graph WHERE latch='Ω Ohms Tennis Ball 〄' and origid=1;
SELECT
*
FROM
graph
WHERE
latch
=
'Ω Ohms Tennis Ball 〄'
and
destid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
'Ω Ohms Tennis Ball 〄'
and
origid
=
666
;
#-- Note the next line couter-intuitively produces no warning
SELECT
*
FROM
graph
WHERE
latch
=
'Ω Ohms Tennis Ball 〄'
and
origid
=
NULL
;
SELECT
*
FROM
graph
WHERE
latch
=
'Ω Ohms Tennis Ball 〄'
and
origid
is
NULL
;
#--echo # Expect no result, because of NULL latch
#-- FIXME - in v2 according to http://openquery.com/graph/doc NULL latch should
#-- FIXME - return same as select * from graph;
#--https://bugs.launchpad.net/oqgraph/+bug/1196021
#SELECT * FROM graph WHERE latch=NULL;
#SELECT * FROM graph WHERE latch=NULL and destid=2 and origid=1;
#SELECT * FROM graph WHERE latch=NULL and origid=1;
#SELECT * FROM graph WHERE latch=NULL and destid=1;
#SELECT * FROM graph WHERE latch=NULL and origid=666;
#SELECT * FROM graph WHERE latch=NULL and origid=NULL;
--
echo
# Return all edges when latch is NULL
SELECT
*
FROM
graph
WHERE
latch
is
NULL
;
SELECT
*
FROM
graph
WHERE
latch
is
NULL
and
destid
=
2
and
origid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
is
NULL
and
origid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
is
NULL
and
destid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
is
NULL
and
origid
=
666
;
SELECT
*
FROM
graph
WHERE
latch
is
NULL
and
origid
is
NULL
;
#-- what happens if we have two links the same? primay key violation...
--
error
1062
...
...
@@ -116,17 +117,18 @@ INSERT INTO graph_base(from_id, to_id) VALUES (1,2);
DELETE
FROM
graph_base
;
#-- Uncomment the following after fixing https://bugs.launchpad.net/oqgraph/+bug/1195735
#-- FIXME
SELECT * FROM graph;
SELECT
*
FROM
graph
;
FLUSH
TABLES
;
TRUNCATE
TABLE
graph_base
;
#-- Uncomment the following after fixing https://bugs.launchpad.net/oqgraph/+bug/xxxxxxx - Causes the later select to not fail!
#-- For now dont report a separate bug as it may be a manifestation of https://bugs.launchpad.net/oqgraph/+bug/1195735
#-- FIXME
SELECT * FROM graph;
SELECT
*
FROM
graph
;
#-- Expect error if we pull the table out from under
DROP
TABLE
graph_base
;
FLUSH
TABLES
;
--
error
S42S02
SELECT
*
FROM
graph
WHERE
latch
=
'dijkstras'
AND
origid
=
1
AND
destid
=
6
;
...
...
mysql-test/suite/oqgraph/create_attr.result
View file @
66e8439d
...
...
@@ -71,7 +71,7 @@ DROP TABLE IF EXISTS oqtable;
CREATE TABLE oqtable ( latch varchar(32) NULL, origid BIGINT UNSIGNED NULL, destid BIGINT UNSIGNED NULL, weight DOUBLE NULL, seq BIGINT UNSIGNED NULL, linkid BIGINT UNSIGNED NULL, KEY (latch, origid, destid) USING HASH, KEY (latch, destid, origid) USING HASH ) ENGINE=OQGRAPH, DATA_TABLE='backing',ORIGID='not_id_type', DESTID='id2';
# Expect 'Column 'backing.not_id_type' is not a not-null integer type'
DESCRIBE oqtable;
ERROR HY000: Got error -1 'Column 'backing.not_id_type' is not a not-null integer type' from OQGRAPH
ERROR HY000: Got error -1 'Column 'backing.not_id_type'
(origid)
is not a not-null integer type' from OQGRAPH
DROP TABLE IF EXISTS oqtable;
CREATE TABLE oqtable ( latch varchar(32) NULL, origid BIGINT UNSIGNED NULL, destid BIGINT UNSIGNED NULL, weight DOUBLE NULL, seq BIGINT UNSIGNED NULL, linkid BIGINT UNSIGNED NULL, KEY (latch, origid, destid) USING HASH, KEY (latch, destid, origid) USING HASH ) ENGINE=OQGRAPH, DATA_TABLE='backing',ORIGID='id';
# Expect 'Invalid OQGRAPH backing store (unspecified or empty destid attribute)'
...
...
@@ -91,7 +91,7 @@ DROP TABLE IF EXISTS oqtable;
CREATE TABLE oqtable ( latch varchar(32) NULL, origid BIGINT UNSIGNED NULL, destid BIGINT UNSIGNED NULL, weight DOUBLE NULL, seq BIGINT UNSIGNED NULL, linkid BIGINT UNSIGNED NULL, KEY (latch, origid, destid) USING HASH, KEY (latch, destid, origid) USING HASH ) ENGINE=OQGRAPH, DATA_TABLE='backing',ORIGID='id',DESTID='not_id_type';
# Expect 'Column 'backing.not_id_type' is not a not-null integer type'
DESCRIBE oqtable;
ERROR HY000: Got error -1 'Column 'backing.not_id_type'
is not a not-null integer type
' from OQGRAPH
ERROR HY000: Got error -1 'Column 'backing.not_id_type'
(destid) is not a not-null integer type or is a different type to origi
' from OQGRAPH
DROP TABLE IF EXISTS oqtable;
CREATE TABLE oqtable ( latch varchar(32) NULL, origid BIGINT UNSIGNED NULL, destid BIGINT UNSIGNED NULL, weight DOUBLE NULL, seq BIGINT UNSIGNED NULL, linkid BIGINT UNSIGNED NULL, KEY (latch, origid, destid) USING HASH, KEY (latch, destid, origid) USING HASH ) ENGINE=OQGRAPH, DATA_TABLE='backing',ORIGID='id',DESTID='id';
# Expect 'Invalid OQGRAPH backing store ('/oqtable'.destid attribute set to same column as origid attribute)'
...
...
@@ -111,7 +111,7 @@ DROP TABLE IF EXISTS oqtable;
CREATE TABLE oqtable ( latch varchar(32) NULL NULL, origid BIGINT UNSIGNED NULL, destid BIGINT UNSIGNED NULL, weight DOUBLE NULL, seq BIGINT UNSIGNED NULL, linkid BIGINT UNSIGNED NULL, KEY (latch, origid, destid) USING HASH, KEY (latch, destid, origid) USING HASH ) ENGINE=OQGRAPH, DATA_TABLE='backing',ORIGID='id',DESTID='id2',WEIGHT='not_weight_type';
# Expect 'Column 'backing.not_weight_type' is not a not-null real type'
DESCRIBE oqtable;
ERROR HY000: Got error -1 'Column 'backing.not_weight_type' is not a not-null real type' from OQGRAPH
ERROR HY000: Got error -1 'Column 'backing.not_weight_type'
(weight)
is not a not-null real type' from OQGRAPH
DROP TABLE IF EXISTS oqtable;
CREATE TABLE oqtable ( latch varchar(32) NULL NULL, origid BIGINT UNSIGNED NULL, destid BIGINT UNSIGNED NULL, weight DOUBLE NULL, seq BIGINT UNSIGNED NULL, linkid BIGINT UNSIGNED NULL, KEY (latch, origid, destid) USING HASH, KEY (latch, destid, origid) USING HASH ) ENGINE=OQGRAPH, DATA_TABLE='backing',ORIGID='id',DESTID='id2',WEIGHT='weight';
DESCRIBE oqtable;
...
...
mysql-test/suite/oqgraph/create_attr_legacy.result
0 → 100644
View file @
66e8439d
This diff is collapsed.
Click to expand it.
mysql-test/suite/oqgraph/create_attr_legacy.test
0 → 100644
View file @
66e8439d
This diff is collapsed.
Click to expand it.
mysql-test/suite/oqgraph/regression_drop_after.result
0 → 100644
View file @
66e8439d
DROP TABLE IF EXISTS graph_base;
DROP TABLE IF EXISTS graph;
CREATE TABLE graph_base (
from_id INT UNSIGNED NOT NULL,
to_id INT UNSIGNED NOT NULL,
PRIMARY KEY (from_id,to_id),
INDEX (to_id)
) ENGINE=MyISAM;
CREATE TABLE graph (
latch VARCHAR(32) NULL,
origid BIGINT UNSIGNED NULL,
destid BIGINT UNSIGNED NULL,
weight DOUBLE NULL,
seq BIGINT UNSIGNED NULL,
linkid BIGINT UNSIGNED NULL,
KEY (latch, origid, destid) USING HASH,
KEY (latch, destid, origid) USING HASH
) ENGINE=OQGRAPH DATA_TABLE='graph_base' ORIGID='from_id', DESTID='to_id';
INSERT INTO graph_base(from_id, to_id) VALUES (1,2), (2,1);
SELECT * FROM graph;
latch origid destid weight seq linkid
NULL 1 2 1 NULL NULL
NULL 2 1 1 NULL NULL
DROP TABLE graph_base;
FLUSH TABLES;
SELECT * FROM graph;
ERROR 42S02: Table 'test.graph_base' doesn't exist
DROP TABLE graph;
mysql-test/suite/oqgraph/regression_drop_after.test
0 → 100644
View file @
66e8439d
--
disable_warnings
DROP
TABLE
IF
EXISTS
graph_base
;
DROP
TABLE
IF
EXISTS
graph
;
--
enable_warnings
# Create the backing store
CREATE
TABLE
graph_base
(
from_id
INT
UNSIGNED
NOT
NULL
,
to_id
INT
UNSIGNED
NOT
NULL
,
PRIMARY
KEY
(
from_id
,
to_id
),
INDEX
(
to_id
)
)
ENGINE
=
MyISAM
;
CREATE
TABLE
graph
(
latch
VARCHAR
(
32
)
NULL
,
origid
BIGINT
UNSIGNED
NULL
,
destid
BIGINT
UNSIGNED
NULL
,
weight
DOUBLE
NULL
,
seq
BIGINT
UNSIGNED
NULL
,
linkid
BIGINT
UNSIGNED
NULL
,
KEY
(
latch
,
origid
,
destid
)
USING
HASH
,
KEY
(
latch
,
destid
,
origid
)
USING
HASH
)
ENGINE
=
OQGRAPH
DATA_TABLE
=
'graph_base'
ORIGID
=
'from_id'
,
DESTID
=
'to_id'
;
INSERT
INTO
graph_base
(
from_id
,
to_id
)
VALUES
(
1
,
2
),
(
2
,
1
);
SELECT
*
FROM
graph
;
DROP
TABLE
graph_base
;
FLUSH
TABLES
;
# <-- without this, we still had it open so never see error...
--
error
S42S02
SELECT
*
FROM
graph
;
DROP
TABLE
graph
;
# gdb script:
# bre ha_oqgraph::rnd_init
# ignore 1 1
# run
storage/oqgraph/ha_oqgraph.cc
View file @
66e8439d
...
...
@@ -646,7 +646,7 @@ int ha_oqgraph::open(const char *name, int mode, uint test_if_locked)
if
((
*
field
)
->
cmp_type
()
!=
INT_RESULT
||
!
((
*
field
)
->
flags
&
NOT_NULL_FLAG
))
{
fprint_error
(
"Column '%s.%s' is not a not-null integer type"
,
fprint_error
(
"Column '%s.%s'
(origid)
is not a not-null integer type"
,
options
->
table_name
,
options
->
origid
);
closefrm
(
edges
,
0
);
free_table_share
(
share
);
...
...
@@ -671,7 +671,7 @@ int ha_oqgraph::open(const char *name, int mode, uint test_if_locked)
if
((
*
field
)
->
type
()
!=
origid
->
type
()
||
!
((
*
field
)
->
flags
&
NOT_NULL_FLAG
))
{
fprint_error
(
"Column '%s.%s'
is not a not-null integer type
"
,
fprint_error
(
"Column '%s.%s'
(destid) is not a not-null integer type or is a different type to origid attribute.
"
,
options
->
table_name
,
options
->
destid
);
closefrm
(
edges
,
0
);
free_table_share
(
share
);
...
...
@@ -703,7 +703,7 @@ int ha_oqgraph::open(const char *name, int mode, uint test_if_locked)
if
((
*
field
)
->
result_type
()
!=
REAL_RESULT
||
!
((
*
field
)
->
flags
&
NOT_NULL_FLAG
))
{
fprint_error
(
"Column '%s.%s' is not a not-null real type"
,
fprint_error
(
"Column '%s.%s'
(weight)
is not a not-null real type"
,
options
->
table_name
,
options
->
weight
);
closefrm
(
edges
,
0
);
free_table_share
(
share
);
...
...
@@ -1050,7 +1050,7 @@ int ha_oqgraph::fill_record(byte *record, const open_query::row &row)
int
ha_oqgraph
::
rnd_init
(
bool
scan
)
{
edges
->
file
->
info
(
HA_STATUS_VARIABLE
);
// Fix for bug 1195735, hang after truncate table - ensure we operate with up to date count
edges
->
file
->
info
(
HA_STATUS_VARIABLE
|
HA_STATUS_CONST
);
// Fix for bug 1195735, hang after truncate table - ensure we operate with up to date count
edges
->
prepare_for_position
();
return
error_code
(
graph
->
random
(
scan
));
}
...
...
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