Changeset: 96b33d581e1d for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=96b33d581e1d
Modified Files:
monetdb5/extras/jaql/json.c
Branch: Jul2012
Log Message:
extract: don't insert JSON null for unmatchable search elements
nil elements typically happen as side-effect of outerjoins (when other
inputs were to be preserved in a jaql join) but extracting them as
separate null entries just causes trouble down the road because these
ghost nulls also count in counts
diffs (16 lines):
diff --git a/monetdb5/extras/jaql/json.c b/monetdb5/extras/jaql/json.c
--- a/monetdb5/extras/jaql/json.c
+++ b/monetdb5/extras/jaql/json.c
@@ -1153,11 +1153,8 @@ JSONextract(int *rkind, int *rstring, in
if (v != oid_nil) {
z = json_copy_entry(bik, bis, bii, bid, bia, bio, bin,
*startoid, v, &jb, &jbr);
- } else {
- BUNappend(jbr.kind, "n", FALSE);
- z = BUNlast(jbr.kind) - 1 + *startoid;
+ BUNins(jbr.array, &w, &z, FALSE);
}
- BUNins(jbr.array, &w, &z, FALSE);
}
unloadbats();
_______________________________________________
Checkin-list mailing list
[email protected]
http://mail.monetdb.org/mailman/listinfo/checkin-list