1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

- Fix the default length for DOUBLE to 255 (was 256, max is 255)

Add a trace in MakeSQL

modified:
  storage/connect/myconn.cpp
  storage/connect/tabmysql.cpp
This commit is contained in:
Olivier Bertrand
2013-10-02 19:58:49 +02:00
parent 069edfe125
commit 8619da05d9
2 changed files with 4 additions and 1 deletions

View File

@@ -166,7 +166,7 @@ PQRYRES MyColumns(PGLOBAL g, const char *host, const char *db,
// Get type, type name, and precision
fld = myc.GetCharField(1);
prec = 0;
len = 256; // Default for text or blob
len = 255; // Default for text or blob
if ((nf = sscanf(fld, "%[^(](%d,%d", cmd, &len, &prec)) < 1) {
sprintf(g->Message, MSG(BAD_FIELD_TYPE), fld);

View File

@@ -507,6 +507,9 @@ bool TDBMYSQL::MakeSelect(PGLOBAL g)
if (To_Filter)
strcat(strcat(Query, " WHERE "), To_Filter);
if (trace)
htrc("Query=%s\n", Query);
// Now we know how much to suballocate
PlugSubAlloc(g, NULL, strlen(Query) + 1);
return FALSE;