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
83a23f31
Commit
83a23f31
authored
May 31, 2013
by
Andrew McDonnell
Browse files
Options
Browse Files
Download
Plain Diff
Added tests for no latch specified.
parents
f8d91216
7032a3cf
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
0 deletions
+18
-0
mysql-test/suite/oqgraph/basic.result
mysql-test/suite/oqgraph/basic.result
+14
-0
mysql-test/suite/oqgraph/basic.test
mysql-test/suite/oqgraph/basic.test
+4
-0
No files found.
mysql-test/suite/oqgraph/basic.result
View file @
83a23f31
...
...
@@ -83,6 +83,20 @@ latch origid destid weight seq linkid
# Expect no result, because of NULL latch
SELECT * FROM graph WHERE latch=NULL and destid=2 and origid=1;
latch origid destid weight seq linkid
# With no latch, original data, filtered by destid, etc if present
SELECT * FROM graph;
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 destid=2 and origid=1;
latch origid destid weight seq linkid
NULL 1 2 1 NULL NULL
SELECT * FROM graph WHERE latch = 'breadth_first' AND origid = 1 AND (weight = 1 OR weight = 2);
latch origid destid weight seq linkid
breadth_first 1 NULL 2 4 4
...
...
mysql-test/suite/oqgraph/basic.test
View file @
83a23f31
...
...
@@ -90,6 +90,10 @@ SELECT * FROM graph WHERE latch=0 and destid=2 and origid=1;
--
echo
# Expect no result, because of NULL latch
SELECT
*
FROM
graph
WHERE
latch
=
NULL
and
destid
=
2
and
origid
=
1
;
--
echo
# With no latch, original data, filtered by destid, etc if present
SELECT
*
FROM
graph
;
SELECT
*
FROM
graph
WHERE
destid
=
2
and
origid
=
1
;
SELECT
*
FROM
graph
WHERE
latch
=
'breadth_first'
AND
origid
=
1
AND
(
weight
=
1
OR
weight
=
2
);
--
echo
# Now we add a connection from 4->6
...
...
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