Subject | Re: [firebird-php] Characterset conversion |
---|---|
Author | Walter Neumann |
Post date | 2008-03-10T12:13:26Z |
Hello,
thank you for your response. I tried it with Database workbench and recieved
the same error. So it seems, that the API of Firebird 1.5 is not able to
convert the data.
As it is not possible in this case to update the database server to 2.0 I have
to covert the data manually with iconv.
Thanks for your assistance.
Walter Neumann
Am Montag, 10. März 2008 11:47 schrieb Milan Babuskov:
Mit freundlichen Grüßen
Bürostudio Neumann
Walter Neumann
Am Birting 1, 2132 Hörersdorf
Österreich
Tel. +43 664/1826291
Skype: wneumann1
Email: walter@...
Internet: http://www.buerostudio-neumann.at
thank you for your response. I tried it with Database workbench and recieved
the same error. So it seems, that the API of Firebird 1.5 is not able to
convert the data.
As it is not possible in this case to update the database server to 2.0 I have
to covert the data manually with iconv.
Thanks for your assistance.
Walter Neumann
Am Montag, 10. März 2008 11:47 schrieb Milan Babuskov:
> Walter Neumann wrote:--
> >>> I have a database on Firebird 1.5 on a windows server with the
> >>> characterset WIN1252. Now I have request some data with PHP with
> >>> characterset UTF-8. What would be the best way to convert the data?
> >>> 2. Is it right, if I connect to the database with UTF-8, that the
> >>> database engine convert the data itselve?
> >>
> >> Yes, that's right.
> >>
> >> If you need everything in UTF-8 on the client side, than it's also the
> >> best way.
> >
> > Thank you for your suggestion. But it don't work. By the statement
> > ibase_fetch_object I recieve the error "arithmetic exception, numeric
> > overflow or string truncation". A typical error, if the charset don't
> > match.
>
> That would mean that Firebird cannot translate WIN1252->UTF8 which is,
> well, impossible. I haven't tried with Firebird 1.5, but with 2.0 it
> works fine.
>
> If you use some admin. tool (ex. FlameRobin) and set UTF-8 as connection
> charset, do you get the same error?
>
> > charset in ibase_connect is UTF-8. What could be wrong?
>
> It's hard to tell, as everything seems fine the way you wrote it. Is
> there some chance you can test with Firebird 2?
Mit freundlichen Grüßen
Bürostudio Neumann
Walter Neumann
Am Birting 1, 2132 Hörersdorf
Österreich
Tel. +43 664/1826291
Skype: wneumann1
Email: walter@...
Internet: http://www.buerostudio-neumann.at