summaryrefslogtreecommitdiff
path: root/src/runtime/c
diff options
context:
space:
mode:
authorkrasimir <krasimir@chalmers.se>2015-09-04 16:34:40 +0000
committerkrasimir <krasimir@chalmers.se>2015-09-04 16:34:40 +0000
commitea83efa79c7d35c8889e1849dc2a604d7aef99cb (patch)
tree57a5c1228e651ec47d007e5e6ff88b581c44d360 /src/runtime/c
parent3d60ce06bb5ba7d52912b4dee19069e606b54a0e (diff)
fix the metadata for sg databases
Diffstat (limited to 'src/runtime/c')
-rw-r--r--src/runtime/c/sg/sg.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/runtime/c/sg/sg.c b/src/runtime/c/sg/sg.c
index c0f8f5dda..ea9199518 100644
--- a/src/runtime/c/sg/sg.c
+++ b/src/runtime/c/sg/sg.c
@@ -49,7 +49,7 @@ sg_open(const char *filename,
rc = sqlite3_exec(db, "create table if not exists " SG_EXPRS "(fun not null, arg integer);"
"create unique index if not exists " SG_IDENTS " on " SG_EXPRS "(fun) where arg is null;"
"create unique index if not exists " SG_LITERALS " on " SG_EXPRS "(fun) where arg = 0;"
- "create unique index if not exists " SG_PAIRS " on " SG_EXPRS "(fun,arg) where arg is not null;"
+ "create unique index if not exists " SG_PAIRS " on " SG_EXPRS "(fun,arg) where arg > 0;"
"create table if not exists " SG_TRIPLES "(subj integer, pred integer, obj integer, state integer);"
"create unique index if not exists " SG_TRIPLES_SPO " on " SG_TRIPLES "(subj,pred,obj);"
"create index if not exists " SG_TRIPLES_PO " on " SG_TRIPLES "(pred,obj);"