Subject | Re: [firebird-support] embedded database with Chinese path |
---|---|
Author | Richard Damon |
Post date | 2017-10-05T11:48:33Z |
On 10/4/17 11:53 PM, Hamish Moffatt hamish@...
[firebird-support] wrote:
characters, only the Extended Ascii character set of the current code
page (so it may seem you can put some unicode in them). SFNs can't be
UTF-8. Note, that this also means that changing the system code page
might change the apparent name of a file that used the extended
character set, even the separator might change (on the Japanese code
page, that is the Yen symbol).
The big selling point of Long File Names (LFN) was that they could be
mostly arbitrary phrases in the users own language, breaking BOTH the 8
character limit AND the 8 bit char restriction (using 16 bit wchar to
encode them). There is no such beast as a 8 bit only LFN, or a 16 bit
(Unicode) encoded SFN.
Every file has a SFN just so that applications (like it appears that
Firebird is) that don't support LFNs can still access the files.
--
Richard Damon
[firebird-support] wrote:
>One thing to note, the Short File Names (SFN) can't use 'Unicode'
> On 04/10/17 22:15, DougC doug@... [firebird-support] wrote:
>> Hamish-
>>
>> Windows short path names are decidedly NOT for apps that cannot
>> handle Unicode. They were introduced far earlier than that and were
>> intended for programs that could not handle anything but the short
>> 8.3 limits for any given file or folder name. That they often help
>> with avoiding unicode is a side effect.
>>
>> Sound like your misunderstanding of this may be contributing to your
>> frustration.
>
> Doug,
>
> I'm aware that short filenames are a work around for applications
> which can't support long filenames (which date from Windows 95). They
> also seem to nicely work around applications which are too dumb to
> support valid Windows 16-bit filenames, like Firebird. I don't agree
> that it's just a side effect that they avoid unicode, since I had
> unicode parts that fit in the 8.3 short filename format.
>
> I realise that Firebird needs to use either long or short names
> consistently so as to avoid inadvertently opening the same file by
> different names (with locking issues and the like), but the solution
> is to use only short names or handle long names properly.
>
> Hamish
>
characters, only the Extended Ascii character set of the current code
page (so it may seem you can put some unicode in them). SFNs can't be
UTF-8. Note, that this also means that changing the system code page
might change the apparent name of a file that used the extended
character set, even the separator might change (on the Japanese code
page, that is the Yen symbol).
The big selling point of Long File Names (LFN) was that they could be
mostly arbitrary phrases in the users own language, breaking BOTH the 8
character limit AND the 8 bit char restriction (using 16 bit wchar to
encode them). There is no such beast as a 8 bit only LFN, or a 16 bit
(Unicode) encoded SFN.
Every file has a SFN just so that applications (like it appears that
Firebird is) that don't support LFNs can still access the files.
--
Richard Damon