Kbase P158519: Xml-schema does not contain initial value when this value is unknown
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  20/01/2010 |
|
Status: Unverified
SYMPTOM(s):
Xml-schema does not contain initial value when this value is unknown
The following information is missing: <xsd:element name="c" type="xsd:string" nilable="true" prodata:initial="prodata:unknown"/>
If the initial value of a character field in the temp-table that is being passed to the server (or client) is unknown, the prodata:initial="prodata:unknown" information is missing in the xsd
FACT(s) (Environment):
The problem is observed when passing the table-handle from the client to the server (or vice versa)
The problem is not observed when both the temp-table and the xml are created on the client
The problem is not observed when both the temp-table and the xml are created on the server
Creating a record based on the table-handle results in the correct initial value being used
WRITE-XML is returning a LONGCHAR
Windows XP
OpenEdge 10.1C04 Service Pack
OpenEdge 10.2A
CAUSE:
Bug# OE00194708
FIX:
A workaround is to modify the LONGCHAR returned by the WRITE-XML:
PROCEDURE RestoreInitialValues PRIVATE:
DEFINE INPUT-OUTPUT PARAMETER io_lccontext AS LONGCHARNO-UNDO.
DEFINE VARIABLE iend_point AS INTEGER NO-UNDO.
DEFINE VARIABLE lcreplace_part AS LONGCHAR NO-UNDO.
DEFINE VARIABLE lcfixed_part AS LONGCHAR NO-UNDO.
iend_point = INDEX (io_lccontext, "</xsd:schema>":U).
IF iend_point > 0 THEN
ASSIGN lcreplace_part = SUBSTRING (io_lccontext, 1, iend_point)
lcfixed_part = SUBSTRING (io_lccontext, iend_point + 1)
io_lccontext = REPLACE (lcreplace_part, 'nillable="true" prodata:format':U, 'nillable="true" prodata:initial="prodata:unknown" prodata:format':U) + lcfixed_part.
END PROCEDURE. /* RestoreInitialValues */