Reading multiple record formats from an xml file
I am trying to use the toolkit_file_xmllist_input adapter, and specifically the xmllistMatchStreamName property. Here's what the manual says about it:
Property ID: matchStreamName (note the manual is missing the "xmllist" prefix)
(Optional) If set to true, the XML element names are matched against the stream name. The adapter discards messages with unmatched values.
I take this to mean that if the xml file has multiple elements, this adapter will distribute their contents to appropriate input streams that have the same name as the element (if the streams exist).
I can't get this to work. Also, when I try to perform discovery on this adapter, I get an Unable to perform discovery on adapter error.
Can someone please help? See the test project and data below. I would like the adapter to route data to the Employee and Address streams.
The main question here is, can I separate different records from a single xml file with this or another adapter?
Thanks in advance,
CREATE SCHEMA S_Employee (
CREATE SCHEMA S_Address (
CREATE INPUT STREAM NEWSTREAM SCHEMA (Column1 INTEGER);
CREATE INPUT STREAM Employees SCHEMA S_Employee;
CREATE INPUT STREAM Addresses SCHEMA S_Address;
ATTACH INPUT ADAPTER employees TYPE toolkit_file_xmllist_input to NEWSTREAM
dir = 'C:/Users/tarnower/Documents/SybaseESP/5.1/workspace/xmltest' ,
file = 'employees.xml',
xmllistMatchStreamName = TRUE
<?xml version='1.0' encoding='utf-8'?>