Changeset: 4c98bfe6f0f1 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/4c98bfe6f0f1
Modified Files:
        clients/Tests/exports.stable.out
        monetdb5/modules/mal/tablet.c
        monetdb5/modules/mal/tablet.h
Branch: Dec2023
Log Message:

Removed unused function TABLETcollect_parts.


diffs (79 lines):

diff --git a/clients/Tests/exports.stable.out b/clients/Tests/exports.stable.out
--- a/clients/Tests/exports.stable.out
+++ b/clients/Tests/exports.stable.out
@@ -799,7 +799,6 @@ int QLOGisset(void);
 str RMTdisconnect(void *ret, str *conn);
 BUN SQLload_file(Client cntxt, Tablet *as, bstream *b, stream *out, const char 
*csep, const char *rsep, char quote, lng skip, lng maxrow, int best, bool 
from_stdin, const char *tabnam, bool escape);
 str TABLETcollect(BAT **bats, Tablet *as);
-str TABLETcollect_parts(BAT **bats, Tablet *as, BUN offset);
 str TABLETcreate_bats(Tablet *as, BUN est);
 void TABLETdestroy_format(Tablet *as);
 int TABLEToutput_file(Tablet *as, BAT *order, stream *s);
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
@@ -185,53 +185,6 @@ TABLETcollect(BAT **bats, Tablet *as)
        return MAL_SUCCEED;
 }
 
-str
-TABLETcollect_parts(BAT **bats, Tablet *as, BUN offset)
-{
-       Column *fmt = as->format;
-       BUN i, j;
-       BUN cnt = 0;
-
-       for (i = 0; i < as->nr_attrs && !cnt; i++)
-               if (!fmt[i].skip)
-                       cnt = BATcount(fmt[i].c);
-       for (i = 0, j = 0; i < as->nr_attrs; i++) {
-               BAT *b, *bv = NULL;
-               if (fmt[i].skip)
-                       continue;
-               b = fmt[i].c;
-               b->tsorted = b->trevsorted = false;
-               b->tkey = false;
-               BATsettrivprop(b);
-               if ((b = BATsetaccess(b, BAT_READ)) == NULL) {
-                       fmt[i].c = NULL;
-                       throw(SQL, "copy",
-                                 "Failed to set access at tablet part " BUNFMT 
"\n", cnt);
-               }
-               bv = BATslice(b, (offset > 0) ? offset - 1 : 0, BATcount(b));
-               bats[j] = bv;
-
-               b->tkey = (offset > 0) ? FALSE : bv->tkey;
-               b->tnonil &= bv->tnonil;
-               if (b->tsorted != bv->tsorted)
-                       b->tsorted = false;
-               if (b->trevsorted != bv->trevsorted)
-                       b->trevsorted = false;
-               if (BATtdense(b))
-                       b->tkey = true;
-
-               if (offset > 0) {
-                       BBPunfix(bv->batCacheid);
-                       bats[j] = BATslice(b, offset, BATcount(b));
-               }
-               if (cnt != BATcount(b))
-                       throw(SQL, "copy", "Count " BUNFMT " differs from " 
BUNFMT "\n",
-                                 BATcount(b), cnt);
-               j++;
-       }
-       return MAL_SUCCEED;
-}
-
 // the starting quote character has already been skipped
 
 static char *
diff --git a/monetdb5/modules/mal/tablet.h b/monetdb5/modules/mal/tablet.h
--- a/monetdb5/modules/mal/tablet.h
+++ b/monetdb5/modules/mal/tablet.h
@@ -78,7 +78,6 @@ mal_export BUN SQLload_file(Client cntxt
                                                        const char *tabnam, 
bool escape);
 mal_export str TABLETcreate_bats(Tablet *as, BUN est);
 mal_export str TABLETcollect(BAT **bats, Tablet *as);
-mal_export str TABLETcollect_parts(BAT **bats, Tablet *as, BUN offset);
 mal_export void TABLETdestroy_format(Tablet *as);
 mal_export int TABLEToutput_file(Tablet *as, BAT *order, stream *s);
 mal_export str COPYrejects(Client cntxt, MalBlkPtr mb, MalStkPtr stk,
_______________________________________________
checkin-list mailing list -- checkin-list@monetdb.org
To unsubscribe send an email to checkin-list-le...@monetdb.org

Reply via email to