Changeset: fbcf571a9e33 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=fbcf571a9e33
Modified Files:
        monetdb5/modules/atoms/mtime.c
        sql/backends/monet5/sql_round_impl.h
        sql/backends/monet5/sql_time.c
Branch: Oct2020
Log Message:

Fixed more hseqbases


diffs (153 lines):

diff --git a/monetdb5/modules/atoms/mtime.c b/monetdb5/modules/atoms/mtime.c
--- a/monetdb5/modules/atoms/mtime.c
+++ b/monetdb5/modules/atoms/mtime.c
@@ -171,7 +171,7 @@ NAMEBULK##_cand(bat *ret, const bat *bid
        }                                                                       
                                                                \
        off = b1->hseqbase;                                                     
                                                \
        n = canditer_init(&ci, b1, s);                                          
                                \
-       if ((bn = COLnew(b1->hseqbase, TYPE_##OUTTYPE, n, TRANSIENT)) == NULL) 
{ \
+       if ((bn = COLnew(ci.hseq, TYPE_##OUTTYPE, n, TRANSIENT)) == NULL) { \
                msg = createException(MAL, "batmtime." MALFUNC "_cand",         
        \
                          SQLSTATE(HY013) MAL_MALLOC_FAIL);                     
                        \
                goto bailout;                                                   
                                                \
diff --git a/sql/backends/monet5/sql_round_impl.h 
b/sql/backends/monet5/sql_round_impl.h
--- a/sql/backends/monet5/sql_round_impl.h
+++ b/sql/backends/monet5/sql_round_impl.h
@@ -392,7 +392,7 @@ batstr_2dec(Client cntxt, MalBlkPtr mb, 
        }
        off = b->hseqbase;
        q = canditer_init(&ci, b, s);
-       if (!(res = COLnew(b->hseqbase, TPE(TYPE), q, TRANSIENT))) {
+       if (!(res = COLnew(ci.hseq, TPE(TYPE), q, TRANSIENT))) {
                msg = createException(SQL, "sql.dec_" STRING(TYPE), 
SQLSTATE(HY013) MAL_MALLOC_FAIL);
                goto bailout;
        }
@@ -476,7 +476,7 @@ batdec2second_interval(Client cntxt, Mal
        }
        off = b->hseqbase;
        q = canditer_init(&ci, b, s);
-       if (!(res = COLnew(b->hseqbase, TYPE_lng, q, TRANSIENT))) {
+       if (!(res = COLnew(ci.hseq, TYPE_lng, q, TRANSIENT))) {
                msg = createException(SQL, "batcalc.batdec2second_interval", 
SQLSTATE(HY013) MAL_MALLOC_FAIL);
                goto bailout;
        }
diff --git a/sql/backends/monet5/sql_time.c b/sql/backends/monet5/sql_time.c
--- a/sql/backends/monet5/sql_time.c
+++ b/sql/backends/monet5/sql_time.c
@@ -53,7 +53,7 @@ daytime_2time_daytime(Client cntxt, MalB
                        goto bailout;
                }
                q = canditer_init(&ci, b, s);
-               if (!(res = COLnew(b->hseqbase, TYPE_daytime, q, TRANSIENT))) {
+               if (!(res = COLnew(ci.hseq, TYPE_daytime, q, TRANSIENT))) {
                        msg = createException(SQL, 
"batcalc.daytime_2time_daytime", SQLSTATE(HY013) MAL_MALLOC_FAIL);
                        goto bailout;
                }
@@ -155,7 +155,7 @@ second_interval_2_daytime(Client cntxt, 
                        goto bailout;
                }
                q = canditer_init(&ci, b, s);
-               if (!(res = COLnew(b->hseqbase, TYPE_daytime, q, TRANSIENT))) {
+               if (!(res = COLnew(ci.hseq, TYPE_daytime, q, TRANSIENT))) {
                        msg = createException(SQL, 
"batcalc.second_interval_2_daytime", SQLSTATE(HY013) MAL_MALLOC_FAIL);
                        goto bailout;
                }
@@ -283,7 +283,7 @@ str_2time_daytimetz_internal(ptr out, pt
                        goto bailout;
                }
                q = canditer_init(&ci, b, s);
-               if (!(res = COLnew(b->hseqbase, TYPE_daytime, q, TRANSIENT))) {
+               if (!(res = COLnew(ci.hseq, TYPE_daytime, q, TRANSIENT))) {
                        msg = createException(SQL, 
"batcalc.str_2time_daytimetz", SQLSTATE(HY013) MAL_MALLOC_FAIL);
                        goto bailout;
                }
@@ -416,7 +416,7 @@ timestamp_2_daytime(Client cntxt, MalBlk
                        goto bailout;
                }
                q = canditer_init(&ci, b, s);
-               if (!(res = COLnew(b->hseqbase, TYPE_daytime, q, TRANSIENT))) {
+               if (!(res = COLnew(ci.hseq, TYPE_daytime, q, TRANSIENT))) {
                        msg = createException(SQL, 
"batcalc.timestamp_2_daytime", SQLSTATE(HY013) MAL_MALLOC_FAIL);
                        goto bailout;
                }
@@ -497,7 +497,7 @@ date_2_timestamp(Client cntxt, MalBlkPtr
                        goto bailout;
                }
                q = canditer_init(&ci, b, s);
-               if (!(res = COLnew(b->hseqbase, TYPE_timestamp, q, TRANSIENT))) 
{
+               if (!(res = COLnew(ci.hseq, TYPE_timestamp, q, TRANSIENT))) {
                        msg = createException(SQL, "batcalc.date_2_timestamp", 
SQLSTATE(HY013) MAL_MALLOC_FAIL);
                        goto bailout;
                }
@@ -582,7 +582,7 @@ timestamp_2time_timestamp(Client cntxt, 
                        goto bailout;
                }
                q = canditer_init(&ci, b, s);
-               if (!(res = COLnew(b->hseqbase, TYPE_timestamp, q, TRANSIENT))) 
{
+               if (!(res = COLnew(ci.hseq, TYPE_timestamp, q, TRANSIENT))) {
                        msg = createException(SQL, 
"batcalc.timestamp_2time_timestamp", SQLSTATE(HY013) MAL_MALLOC_FAIL);
                        goto bailout;
                }
@@ -711,7 +711,7 @@ str_2time_timestamptz_internal(ptr out, 
                        goto bailout;
                }
                q = canditer_init(&ci, b, s);
-               if (!(res = COLnew(b->hseqbase, TYPE_timestamp, q, TRANSIENT))) 
{
+               if (!(res = COLnew(ci.hseq, TYPE_timestamp, q, TRANSIENT))) {
                        msg = createException(SQL, 
"batcalc.str_2time_timestamptz_internal", SQLSTATE(HY013) MAL_MALLOC_FAIL);
                        goto bailout;
                }
@@ -849,7 +849,7 @@ month_interval_str(Client cntxt, MalBlkP
                        goto bailout;
                }
                q = canditer_init(&ci, b, s);
-               if (!(res = COLnew(b->hseqbase, TYPE_int, q, TRANSIENT))) {
+               if (!(res = COLnew(ci.hseq, TYPE_int, q, TRANSIENT))) {
                        msg = createException(SQL, 
"batcalc.month_interval_str", SQLSTATE(HY013) MAL_MALLOC_FAIL);
                        goto bailout;
                }
@@ -934,7 +934,7 @@ second_interval_str(Client cntxt, MalBlk
                        goto bailout;
                }
                q = canditer_init(&ci, b, s);
-               if (!(res = COLnew(b->hseqbase, TYPE_lng, q, TRANSIENT))) {
+               if (!(res = COLnew(ci.hseq, TYPE_lng, q, TRANSIENT))) {
                        msg = createException(SQL, 
"batcalc.second_interval_str", SQLSTATE(HY013) MAL_MALLOC_FAIL);
                        goto bailout;
                }
@@ -1073,7 +1073,7 @@ month_interval(Client cntxt, MalBlkPtr m
                        goto bailout;
                }
                q = canditer_init(&ci, b, s);
-               if (!(res = COLnew(b->hseqbase, TYPE_int, q, TRANSIENT))) {
+               if (!(res = COLnew(ci.hseq, TYPE_int, q, TRANSIENT))) {
                        msg = createException(SQL, "batcalc.month_interval", 
SQLSTATE(HY013) MAL_MALLOC_FAIL);
                        goto bailout;
                }
@@ -1187,7 +1187,7 @@ second_interval(Client cntxt, MalBlkPtr 
                        goto bailout;
                }
                q = canditer_init(&ci, b, s);
-               if (!(res = COLnew(b->hseqbase, TYPE_lng, q, TRANSIENT))) {
+               if (!(res = COLnew(ci.hseq, TYPE_lng, q, TRANSIENT))) {
                        msg = createException(SQL, "batcalc.sec_interval", 
SQLSTATE(HY013) MAL_MALLOC_FAIL);
                        goto bailout;
                }
@@ -1288,7 +1288,7 @@ second_interval_daytime(Client cntxt, Ma
                        goto bailout;
                }
                q = canditer_init(&ci, b, s);
-               if (!(res = COLnew(b->hseqbase, TYPE_lng, q, TRANSIENT))) {
+               if (!(res = COLnew(ci.hseq, TYPE_lng, q, TRANSIENT))) {
                        msg = createException(SQL, 
"batcalc.second_interval_daytime", SQLSTATE(HY013) MAL_MALLOC_FAIL);
                        goto bailout;
                }
@@ -1416,7 +1416,7 @@ str_2_date_internal(ptr out, ptr in, con
                        goto bailout;
                }
                q = canditer_init(&ci, b, s);
-               if (!(res = COLnew(b->hseqbase, TYPE_date, q, TRANSIENT))) {
+               if (!(res = COLnew(ci.hseq, TYPE_date, q, TRANSIENT))) {
                        msg = createException(SQL, "batcalc.batstr_2_date", 
SQLSTATE(HY013) MAL_MALLOC_FAIL);
                        goto bailout;
                }
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to