Subject | Unnecessary padding to Strings read |
---|---|
Author | Nickolay Samofatov |
Post date | 2003-08-14T20:27:37Z |
Hello Roman,
Another suggestion. You know buffer length for parameter in bytes.
You know what charset set you are using and know how many bytes can
characters occupy in this charset. You also know how to count
characters in this charset. Given this information driver can easily
trim returned string itself.
This is a bit hacky way and can break some things (e.g. you declare
CHAR(80) UNICODE column and store 200 ASCII characters in it, driver
will trim some data), but it will work.
--
Best regards,
Nickolay Samofatov mailto:skidder@...
Another suggestion. You know buffer length for parameter in bytes.
You know what charset set you are using and know how many bytes can
characters occupy in this charset. You also know how to count
characters in this charset. Given this information driver can easily
trim returned string itself.
This is a bit hacky way and can break some things (e.g. you declare
CHAR(80) UNICODE column and store 200 ASCII characters in it, driver
will trim some data), but it will work.
--
Best regards,
Nickolay Samofatov mailto:skidder@...