|Subject||Re: [firebird-support] Impossible to create a new database from a script|
|Author||Walter R. Ojeda Valiente|
|Libre de virus. www.avast.com|
On Sat, Mar 17, 2018 at 11:30 AM, Mark Rotteveel mark@... [firebird-support] <firstname.lastname@example.org> wrote:
On 17-3-2018 16:21, 'Walter R. Ojeda Valiente'
sistemas2000profesional@gmail. com [firebird-support] wrote:
> Hello Mark
> Thank you for your answer.
> I had tried with ISO8859_1 (which is the character set I always use) and
> with WIN1252 and the same (bad) results happens.
> Neither SET NAMES ISO8859_1 nor WIN1252 solve the problem. Same error in
> both cases
> But with UTF8 it works fine.
> However, I want to use ISO8859_1, no UTF8..
> After a database is created with the UTF8, is it possible to change its
> character set to ISO8859_1?
The encoding of the script file is UTF-8, this means that you need to
use UTF8 as the **connection** character set. The problem is not one of
the database or Firebird, but with how the byte sequence in the script
file is to be interpreted. This is done by setting the connection
If you want to use ISO9959_1 instead, then you should save your file
with ISO-8859-1 as encoding.
Alternatively, if you can't easily get your editor to save as ISO-8859-1
or Windows-1252, you will need to use a character set introducer in your
script file, eg
COMMENT ON COLUMN ADICIONALES.ADI_SERVID IS _UTF8'Servidor Nº';
This should instruct Firebird to interpret this specific literal in
UTF-8 and not the current connection character set. You will probably
need to do this for any literal that contains non-ASCII (ie chars other
than 0 - 127).