Subject | Re: [firebird-support] Bug with character sets |
---|---|
Author | Martijn Tonies |
Post date | 2009-05-20T10:00:20Z |
Dimitry,
Having to query the system tables in order to retrieve data from the
API is rather strange, it's a defect in the API, no matter what direction
you look at it.
With regards,
Martijn Tonies
Upscene Productions
http://www.upscene.com
Download Database Workbench for Oracle, MS SQL Server, Sybase SQL
Anywhere, MySQL, InterBase, NexusDB and Firebird!
Database questions? Check the forum:
http://www.databasedevelopmentforum.com
>> But the application's work would be a lot easier if N (orWe don't want VARCHAR, we want CHAR.
>> "bytesactuallyused") were contained in the (X)SQLVAR struct.
>
> And good news are: "bytesactuallyused" is contained. For VARCHAR.
Having to query the system tables in order to retrieve data from the
API is rather strange, it's a defect in the API, no matter what direction
you look at it.
>> Yes, if the struct docs says that the buffer will be padded with spacesWhy do you keep insisting on VARCHAR?
>> up to N codepoints and \0 beyond that. But that would also require that
>> \0 can't occur in the actual data value. I suppose that is and should
>> still be allowed, so i that case the change in padding would not help.
>
> \0 is allowed in cahracter set OCTETS only. All other character sets,
> including NONE, prohibit it.
>
>> But note that noone has asked for that change in padding. What we've
>> been asking for is N or "bytesactuallyused". And that *would* help.
>
> And this is exactly the reason for VARCHAR existence - to have actual
> length on the string.
With regards,
Martijn Tonies
Upscene Productions
http://www.upscene.com
Download Database Workbench for Oracle, MS SQL Server, Sybase SQL
Anywhere, MySQL, InterBase, NexusDB and Firebird!
Database questions? Check the forum:
http://www.databasedevelopmentforum.com