A database and its data can be converted from one code page (the source code page) to another code page (the target code page) if one or both of the following conditions are true:
- Every character that appears in the source code page appears in the target code page.
- Every character that appears in the database appears in the target code page.
To convert a UTF-8 database to iso8859-1:1. Backup the existing database, if conversion fails this will render the database unusable.
2. Analyze the impact of doing a codepage conversion on the database to evaluate whether any data will be lost.
Convchar analyze will identify fields where the data will change if you were to run
convchar convert.
If there are fields that have non Western European data then it will list those fields after the 3963 message reflected by other messages such as 3965 and 10001. If converting from UTF-8, will result in data loss, run an ABL program to look for characters in the field(s) identified by convchar analyze:
$ proutil dbname -C convchar analyze iso8859-1
3. Dump the existing database using the Data Administration tool. Do not define the codepage as "undefine" leave it as utf-8.
4. Create a new empty iso8859-1 database with the required blocksize
<x>
$ prodb dbname <DLC>\prolang\eng\empty<x>.db
5. Compile a new version of word break table for iso8859-1 to a rule number <N>
$ proutil dbname -C wbreak-compiler <DLC>\prolang\convmap\iso01bas.wbt file
Where:
<N> - a number between 1 and 255.
<DLC> - Use an absolute path to DLC instead of the environment variable in the command line.
6. Either place the new created file proword.<N> in the install directory (DLC) or define the environment variable PROWD<N>=<file-directory>\proword.<N> (Progress Version 9.0A, set PROWD<N>).
7. Apply the new word-rules to the database:
$ proutil <dbname> -C word-rules <N>
Where:
<N> is the number chosen in Step 5 above.
8. Load the database with the .d files created in Step 3 above.