Changeset: 63f64672ba70 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/63f64672ba70
Modified Files:
gdk/gdk.h
monetdb5/modules/mal/tablet.c
sql/backends/monet5/sql_result.c
Branch: nilmask
Log Message:
outputting a sha256
diffs (54 lines):
diff --git a/gdk/gdk.h b/gdk/gdk.h
--- a/gdk/gdk.h
+++ b/gdk/gdk.h
@@ -1581,7 +1581,7 @@ BATsettrivprop(BAT *b)
b->tmaxpos = 0;
}
b->tseqbase = sqbs;
- } else if ((b->tvheap
+ } else if (ATOMnilptr(b->ttype) && (b->tvheap
? ATOMcmp(b->ttype,
b->tvheap->base +
VarHeapVal(Tloc(b, 0), 0, b->twidth),
ATOMnilptr(b->ttype))
diff --git a/monetdb5/modules/mal/tablet.c b/monetdb5/modules/mal/tablet.c
--- a/monetdb5/modules/mal/tablet.c
+++ b/monetdb5/modules/mal/tablet.c
@@ -283,7 +283,7 @@ output_line(char **buf, size_t *len, cha
if (f->c) {
p = BUNtail(f->ci, f->p);
- if (!p || ATOMcmp(f->adt, ATOMnilptr(f->adt),
p) == 0) {
+ if (!p || (f->nildata && ATOMcmp(f->adt,
f->nildata, p) == 0)) {
p = f->nullstr;
l = (ssize_t) strlen(f->nullstr);
} else {
@@ -327,7 +327,7 @@ output_line_dense(char **buf, size_t *le
if (f->c) {
p = BUNtail(f->ci, f->p);
- if (!p || ATOMcmp(f->adt, ATOMnilptr(f->adt), p) == 0) {
+ if (!p || (f->nildata && ATOMcmp(f->adt, f->nildata, p)
== 0)) {
p = f->nullstr;
l = (ssize_t) strlen(p);
} else {
@@ -368,7 +368,7 @@ output_line_lookup(char **buf, size_t *l
if (f->c) {
const void *p = BUNtail(f->ci, id - f->c->hseqbase);
- if (!p || ATOMcmp(f->adt, ATOMnilptr(f->adt), p) == 0) {
+ if (!p || (f->nildata && ATOMcmp(f->adt, f->nildata, p)
== 0)) {
size_t l = strlen(f->nullstr);
if (mnstr_write(fd, f->nullstr, 1, l) !=
(ssize_t) l)
return TABLET_error(fd);
diff --git a/sql/backends/monet5/sql_result.c b/sql/backends/monet5/sql_result.c
--- a/sql/backends/monet5/sql_result.c
+++ b/sql/backends/monet5/sql_result.c
@@ -1461,6 +1461,8 @@ get_print_width(int mtype, sql_class ecl
return 5; /* max(strlen("true"), strlen("false")) */
} else if (strcmp(ATOMname(mtype), "uuid") == 0) {
return 36; /* xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx */
+ } else if (strcmp(ATOMname(mtype), "sha256") == 0) {
+ return 64;
} else {
return 0;
}
_______________________________________________
checkin-list mailing list -- [email protected]
To unsubscribe send an email to [email protected]