August 23rd, 2013, 07:36 AM
Convert DB from UNICODE_FSS to UTF8
I have a big database that has
DEFAULT CHARACTER SET UNICODE_FSS
In it, i have only one table (more precise, one column) that can contain non-ASCII text. The text can be in any language, so i want the DB, or at least that column to be UTF8, since UNICODE_FSS is old.
Now, i found online hundred of resources for this problem but always for other DBMS (Mysql et c.). The forum that regard Firebird always are without a real answer (like this: database-conversion-from-default-charset-to-utf-8t-675160 .html).
I would like a procedure like:
1. dump your DB (if necessary) -- and how to do that
2. convert it -- and how to do that
3. restore it -- and how to do that
Or something like:
1. add a column to your table with the UTF8 encoding
2. copy the data from the old column to the new
3. delete the old column and rename the new as the old one.
I tried the second way but there are always errors (i used Mysql and postgres and maybe i don't know exactly the syntax for firebird).
Maybe the stupid personalized google search is giving me always the same result pages while i need new ones (because according to them one needs always the same resources and has to solve always the same problems as in the search history...).
How to do this conversion in Firebird?
P.S. If you know some conversion that may damage the current text it's not a problem. If i can convert the DB and this conversion will damage the text it's fine for me because i can restore the text.
August 23rd, 2013, 09:23 AM
I disabled teh google personalized search and I found new pages. Between them, also something that seems working, but doesn't work.
I did this first:
I was very happy when i didn't see any error.
SQL> UPDATE RDB$DATABASE SET RDB$CHARACTER_SET_NAME='UTF8';
But later i run "show database"...
Still UNICODE_FSS !
SQL> show database;
Default Character set: UNICODE_FSS
August 27th, 2013, 02:45 AM
I see there is no answer, i will try to install Firebird on my computer and make experiments (i usually work on a remote server).
Now I need a different info, since i want to install exactly the same version that is on the server (an old one), i need to know the isql command that will tell me which version is installed on the server, so that i will be able to download and install the same version. In this way, i will be able to understand if the problems i have are due to the encoding or to something else.