Kbase P184579: 4GL/ABL: Errors (13036), (13064) invoking READ-XML method
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  3/22/2011 |
|
Status: Unverified
SYMPTOM(s):
4GL/ABL: Errors (13036), (13064) and (13035) invoking READ-XML method
Error reading XML from a MEMPTR or LONGCHAR. (13036)
READ-XML encountered an error while parsing the XML Document: <error>. (13064)
Errors are generated executing code similar to the following snippet:
DEFINE INPUT PARAMETER lcXMLData AS LONGCHAR.
DEFINE TEMP-TABLE ttMyTable NO-UNDO BEFORE-TABLE ttBefore
FIELD iField AS INTEGER
FIELD cField AS CHARACTER.
DEFINE DATASET dsMyTable FOR ttMyTable.
DATASET dsMyTable:READ-XML("LONGCHAR", lcXMLData, "EMPTY",?, FALSE).
Errors are also generated executing code similar to the following snippet:
DEFINE VARIABLE lcXMLData AS LONGCHAR.
DEFINE TEMP-TABLE ttMyTable NO-UNDO BEFORE-TABLE ttBefore
FIELD iField AS INTEGER
FIELD cField AS CHARACTER.
DEFINE DATASET dsMyTable FOR ttMyTable.
DATASET dsMyTable:READ-XML("LONGCHAR", lcXMLData, "EMPTY",?, FALSE).
FACT(s) (Environment):
OpenEdge 10.1B
All Supported Operating Systems
CAUSE:
The errors are generated because the LONGCHAR variable in both cases is empty and has no data to allow READ-XML function to execute error free. In the first code snippet, the procedure is invoked from a WebServices client that is passing an empty LONGCHAR input parameter and in the second code snippet, the LONGCHAR is also empty as it has not been assigned any value.
FIX:
Ensure that the LONGCHAR input parameter/variable is not empty before executing the READ-XML function against it.