Export_to_XML_CLOB

SQL

PROCEDURE Export_to_XML_CLOB(INOUT dad_ref CLOB, INOUT xml CLOB);


Parameters

dad_ref
reference to DAD
xml
name of the variable that will store the XML text


Since version

8.1

Description

This procedure exports data in the XML format to the specified xml CLOB type variable. The data source is described in the DAD. The entire export is a part of a transaction. If an error occurs during export, an exception will be raised.

The dad_ref parameter may have two forms. If it is in the object_name prefixed with an asterisk (*object_name), the DAD will search the current opened application for a transfer type object, otherwise it is read from the specified variable.

The 602xml extension must be loaded in order to export to XML. It is required to prefix the function name with extension name (CALL `602xml`.Export_to_XML). You must load the extension in advance on Linux (before compilation) with the following command:

CALL load_server_extension('602xml')



Example

Export data in the XML format to the specified variable:

DECLARE xml_output, dad CLOB;
SET dad = "*dad_price_list";
CALL `602xml`.Export_to_XML_CLOB(dad,xml_output) ; 

Viz