Changeset: 88768b9907dc for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=88768b9907dc Modified Files: sql/storage/store.c Branch: Jan2014 Log Message:
make sure we correctly set the unique flag on hash - indices with more than one column diffs (18 lines): diff --git a/sql/storage/store.c b/sql/storage/store.c --- a/sql/storage/store.c +++ b/sql/storage/store.c @@ -327,6 +327,14 @@ load_idxcolumn(sql_trans *tr, sql_idx * list_append(i->columns, kc); if (hash_index(i->type)) kc->c->unique = 1; + if (hash_index(i->type) && list_length(i->columns) > 1) { + /* Correct the unique flag of the keys first column */ + kc->c->unique = list_length(i->columns); + if (kc->c->unique == 2) { + sql_kc *ic1 = i->columns->h->data; + ic1->c->unique ++; + } + } } static sql_idx * _______________________________________________ checkin-list mailing list checkin-list@monetdb.org https://www.monetdb.org/mailman/listinfo/checkin-list