Skip to content

Commit 5dce462

Browse files
committed
PDO_ODBC: use displaysize for maxlen and colsize for datalen
1 parent 5a096ae commit 5dce462

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

ext/pdo_odbc/odbc_stmt.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -608,7 +608,8 @@ static int odbc_stmt_describe(pdo_stmt_t *stmt, int colno)
608608
}
609609
colsize = displaysize;
610610

611-
col->maxlen = S->cols[colno].datalen = colsize;
611+
S->cols[colno].datalen = colsize;
612+
col->maxlen = displaysize;
612613
col->name = zend_string_init(S->cols[colno].colname, colnamelen, 0);
613614
S->cols[colno].is_unicode = pdo_odbc_sqltype_is_unicode(S, S->cols[colno].coltype);
614615

0 commit comments

Comments
 (0)