diff --git a/source/mysql_connection.pas b/source/mysql_connection.pas index e7a113f8..08090403 100644 --- a/source/mysql_connection.pas +++ b/source/mysql_connection.pas @@ -658,6 +658,9 @@ begin FDatatypes[i] := Datatypes[Low(Datatypes)]; for j:=Low(Datatypes) to High(Datatypes) do begin if Field._type = Datatypes[j].NativeType then begin + // Text and Blob types share the same constants (see FIELD_TYPEs in mysql_api) + if ((Field.flags and BINARY_FLAG) = BINARY_FLAG) and (Datatypes[j].Category <> dtcBinary) then + continue; FDatatypes[i] := Datatypes[j]; break; end;