Add latch='0' test for completeness'

This commit is contained in:
Andrew McDonnell 2013-08-09 21:15:12 +09:30
parent db048e7855
commit 54e60bcb46
2 changed files with 18 additions and 2 deletions

View file

@ -46,7 +46,7 @@ NULL 12 10 1 NULL NULL
SELECT count(*) FROM graph;
count(*)
13
# Return all edges when latch is NULL
# Return all edges when latch is NULL - this is different to latch='' and same as no where clause
SELECT * FROM graph where latch is NULL;
latch origid destid weight seq linkid
NULL 1 2 1 NULL NULL
@ -76,6 +76,19 @@ latch origid destid weight seq linkid
NULL NULL NULL NULL 10
NULL NULL NULL NULL 11
NULL NULL NULL NULL 12
SELECT * FROM graph where latch='0';
latch origid destid weight seq linkid
0 NULL NULL NULL NULL 1
0 NULL NULL NULL NULL 2
0 NULL NULL NULL NULL 3
0 NULL NULL NULL NULL 4
0 NULL NULL NULL NULL 5
0 NULL NULL NULL NULL 6
0 NULL NULL NULL NULL 7
0 NULL NULL NULL NULL 9
0 NULL NULL NULL NULL 10
0 NULL NULL NULL NULL 11
0 NULL NULL NULL NULL 12
# Currently count should be 11
SELECT count(*) FROM graph where latch='';
count(*)

View file

@ -67,12 +67,15 @@ SELECT * FROM graph;
--echo # Currently count should be 13
SELECT count(*) FROM graph;
--echo # Return all edges when latch is NULL
--echo # Return all edges when latch is NULL - this is different to latch='' and same as no where clause
SELECT * FROM graph where latch is NULL;
--echo # Return all vertices, and subsets of vertices
SELECT * FROM graph where latch='';
SELECT * FROM graph where latch='0';
--echo # Currently count should be 11
SELECT count(*) FROM graph where latch='';
#-- get a subset of vertices
SELECT * FROM graph where latch='' and linkid = 2;