Changeset: 63439203f490 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/63439203f490
Modified Files:
sql/backends/monet5/sql_result.c
Branch: Aug2024
Log Message:
Ignore the reply size from the MAPI protocol when returning the PREPARE result.
This fixes bug #7622.
diffs (21 lines):
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
@@ -1667,7 +1667,7 @@ mvc_export_head(backend *b, stream *s, i
/* row count, min(count, reply_size) */
/* the columnar protocol ignores the reply size by fetching the entire
resultset at once, so don't set it */
- if (mvc_send_int(s, (b->client && b->client->protocol !=
PROTOCOL_COLUMNAR && m->reply_size >= 0 && (BUN) m->reply_size < count) ?
m->reply_size : (int) count) != 1)
+ if (mvc_send_int(s, (b->client && b->client->protocol !=
PROTOCOL_COLUMNAR && m->reply_size >= 0 && (BUN) m->reply_size < count &&
t->query_type != Q_PREPARE) ? m->reply_size : (int) count) != 1)
return -4;
// export query id
@@ -1820,7 +1820,7 @@ mvc_export_result(backend *b, stream *s,
return mvc_export_table_columnar(s, t, m->scanner.rs);
}
- count = m->reply_size;
+ count = t->query_type == Q_PREPARE ? t->nr_rows : (BUN) m->reply_size;
if (m->reply_size != -2 && (count <= 0 || count >= t->nr_rows)) {
count = t->nr_rows;
clean = 1;
_______________________________________________
checkin-list mailing list -- [email protected]
To unsubscribe send an email to [email protected]