Consultor Eletrônico



Kbase P101169: Varchar defined as Long Varchar Incorrectly in ProToOdb using DB2/400 or DB2 Database
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   11/05/2005
Status: Verified

FACT(s) (Environment):

OpenEdge 10.0B
ODBC DataServer

SYMPTOM(s):

Running ProToOdb to DB2/400 Database

Running ProToOdb to DB2 Database

Character field with format greater that X(239) defined as long varchar

Adjust Schema portion of ProToOdb changes foreign type to varchar since DB2 can have up to 4000 bits in a varchar

Loading data gives error (1461)

Schema holder does not match database schema -- file <name> field <name>(1461)

CAUSE:

This is a known issue being investigated by development

FIX:

The work around is to perform each step of the ProToOdb utility separately.

1. Deselect the "Load SQL" option in the ProToOdb utility to create the script.
2. Manually review the schema definitions and change any long varchar definition of a field whose length is less than 4000 to a varchar.
3. Load the SQL script manually into the DB2 database using the native database tool of choice.
4. Run the update DataServer utility and pull the definitions into the schema holder.
5. Run the Schema Migration -> Adjust Schema utility.

The schema holder will now match the file definitions.