I’m trying to create an integration between an oracle database and the XML adapter using the Enterprise Integrator. I created two configured operations. One is a Notification from the database and the other is an operation to generate XML.The notification has an ouput step that creates a document for input into the generateXML operation. Everything look very straight forward but I’m getting an error, or I should say a couple of errors. I ran the XML adapter in debug mode and these are the results:
8:15:47 AM [Debug] CreateHHXML IC load CreateHHXML
8:15:47 AM [Debug] CreateHHXML RO load xmlAdapter:perations::GenerateHHXML
8:15:47 AM [Debug] CreateHHXML created
8:15:47 AM [Debug] CreateHHXML initialize
8:15:47 AM [Debug] CreateHHXML created
8:15:47 AM [Debug] CreateHHXML subscribe DaybreakToHH::Canonical::App_C
8:15:48 AM [Debug] received DaybreakToHH::Canonical::App_C OraTest
8:15:48 AM [Debug] CreateHHXML input DaybreakToHH::Canonical::App_C
8:15:48 AM event DaybreakToHH::Canonical::App_C {
8:15:48 AM unicode_string APP_ID = “5000001”;
8:15:48 AM unicode_string APP_COMP_ID = “”;
8:15:48 AM unicode_string APL_SSN = “999999999”;
8:15:48 AM date APL_BIRTH_DT = “12/22/1964 00:00:00”;
8:15:48 AM unicode_string APL_FIRST_NAME = “JOE”;
8:15:48 AM unicode_string APL_LAST_NAME = “SMITH”;
8:15:48 AM unicode_string APA_ADDRESS_TYPE = “H”;
8:15:48 AM unicode_string APA_HOUSE_NO = “123”;
8:15:48 AM unicode_string APA_ADDRESS1 = “TEST DR”;
8:15:48 AM unicode_string APA_ADDRESS2 = “”;
8:15:48 AM unicode_string APA_CITY = “FANTASY ISLAND”;
8:15:48 AM unicode_string APA_COUNTY = “”;
8:15:48 AM unicode_string APA_STATE = “IL”;
8:15:48 AM unicode_string APA_ZIP = “60750”;
8:15:48 AM unicode_string APA_ZIP_EXTN = “”;
8:15:48 AM unicode_string APA_PHONE = “9999999999”;
8:15:48 AM struct {
8:15:48 AM int tag;
8:15:48 AM unicode_string businessContext;
8:15:48 AM date enqueueTime;
8:15:48 AM date recvTime;
8:15:48 AM unicode_string pubId;
8:15:48 AM int age;
8:15:48 AM } _env = {
8:15:48 AM tag = 11;
8:15:48 AM businessContext = “”;
8:15:48 AM enqueueTime = “08/27/2002 08:15:46.554”;
8:15:48 AM recvTime = “08/27/2002 08:15:46.554”;
8:15:48 AM pubId = “OraTest”;
8:15:48 AM age = 2;
8:15:48 AM };
8:15:48 AM };
8:15:48 AM [Debug] CreateHHXML input ActiveWorks::Adapters::xmlAdapter:perations::GenerateHHXML::input
8:15:48 AM event ActiveWorks::Adapters::xmlAdapter:perations::GenerateHHXML::input {
8:15:48 AM struct {
8:15:48 AM unicode_string app_id;
8:15:48 AM struct {
8:15:48 AM struct {
8:15:48 AM struct {
8:15:48 AM unicode_string part;
8:15:48 AM } xmlattrs;
8:15:48 AM } applicantname;
8:15:48 AM struct {
8:15:48 AM unicode_string xmldata;
8:15:48 AM } taxid;
8:15:48 AM unicode_string dob;
8:15:48 AM struct {
8:15:48 AM unicode_string number;
8:15:48 A
“The field ‘xmlattrs’ could not be found in the document.” is the pertinent part of the error. Double-check your mappings. You probably want to be mapping from xmlattrs.part.
Hi Rob,
I mapped to a different field, one that does not have the ‘xmlattrs’ and I got the same error. I don’t know if the operation is expecting a field called ‘xmlattrs’ or somehow it is receiving a field with that name and is not finding it.
Thanks for your help.
The debug result are the following:
8:15:44 AM [Debug] CreateHHXML input ActiveWorks::Adapters::xmlAdapter:perations::GenerateHHXML::input
8:15:44 AM event ActiveWorks::Adapters::xmlAdapter:perations::GenerateHHXML::input {
8:15:44 AM struct {
8:15:44 AM unicode_string app_id;
8:15:44 AM struct {
8:15:44 AM struct {
8:15:44 AM unicode_string xmldata;
8:15:44 AM } applicantname;
8:15:44 AM struct {
8:15:44 AM unicode_string xmldata;
8:15:44 AM } taxid;
8:15:44 AM unicode_string dob;
8:15:44 AM struct {
8:15:44 AM unicode_string number;
8:15:44 AM struct {
8:15:44 AM unicode_string xmldata;
8:15:44 AM } street;
8:15:44 AM unicode_string city;
8:15:44 AM unicode_string postal;
8:15:44 AM } address;
8:15:44 AM struct {
8:15:44 AM unicode_string xmldata;
8:15:44 AM } phone;
8:15:44 AM } applicant;
8:15:44 AM } application = {
8:15:44 AM {
8:15:44 AM app_id = “5000001”;
8:15:44 AM applicant = {
8:15:44 AM {
8:15:44 AM applicantname = {
8:15:44 AM {
8:15:44 AM xmldata = “JOE”;
8:15:44 AM }
8:15:44 AM };
8:15:44 AM taxid = {
8:15:44 AM xmldata = “999999999”;
8:15:44 AM };
8:15:44 AM dob = “12/22/1964 00:00:00”;
8:15:44 AM address = {
8:15:44 AM {
8:15:44 AM number = “123”;
8:15:44 AM street = {
8:15:44 AM xmldata = “TEST DR”;
8:15:44 AM };
8:15:44 AM city = “FANTASY ISLAND”;
8:15:44 AM postal = “60750”;
8:15:44 AM }
8:15:44 AM };
8:15:44 AM phone = {
8:15:44 AM {
8:15:44 AM xmldata = “9999999999”;
8:15:44 AM }
8:15:44 AM };
8:15:44 AM }
8:15:44 AM };
8:15:44 AM }
8:15:44 AM };
8:15:44 AM };
8:15:44 AM [Debug] CreateHHXML error (059) Could not process request document of type “DaybreakToHH::Canonical::App_C”
8:15:44 AM (108) Could not invoke script “CreateHHXML”
8:15:44 AM (046) Broker error while execution operation “GenerateHHXML”.
8:15:44 AM Field Not Found (203-1090): The field ‘xmlattrs’ could not be found in the document. (BrokerEvent.getStructFieldAsEvent-9251)
8:15:44 AM Field Not Found (203-1090): The field ‘xmlattrs’ could not be found in the document.
It would seem that somewhere within the GenerateHHXML script you’re trying to access xmlattr, which from your second post of the input is not defined anywhere.
If this isn’t the case, perhaps you could send an export of your integration to me and I’ll see what I can find.
I received your .adl file and looked through it. Unfortunately, I didn’t see anything off-hand that looked like it was causing the error. Another bummer is that I don’t have access to the Intelligent XML Adapter so I can’t run any tests myself.
GenerateHHXML is definitely where the error is encountered. My best guess is that there may be some leftover settings in the infoset for ActiveWorks::Adapters::xmlAdapter:perations::GenerateHHXML. I’ve encountered this sort of thing before. You can try to correct it be deleted the configured op and redefining it or you can see if there is an old/errant reference to an xmlattrs struct somewhere in the infoset. In particular, …GenerateHHXML::input::ActiveWorks::parameterValues[4] looks suspicious but I can’t be sure.
What version of the XML Adapter are you using? (4.0, 4.1 or 4.2). If it is a 4.1 version I think I remember we had a similar problem in our environment with the xmlattrs Struct Field type which is the internal data structure the XML adapter uses to keep track of Element attributes. I believe our problem occurred because on a GenerateXML operation we mapped a DTD, but we de-selected a few Elements that we didn’t want in our output document. Well, the Adpater wanted all the Elements checked whether we used them or not!! for it to work. Check that. If that doesn’t solve your problem, I highly recommend upgrading to the latest version of the Adapter (4.2 SP3) and rebuilding your operations. If you are at this version, then disregard this post.
Hi,
I am using Enterprise Server 5.0.1 and XML adapter 4.2 with SP3 and Fixpack2.
I am trying to use the ParseXML configured operation to parse an XML file based on a DTD. However the XML file contains CDATA sections, e.g.
[[!CDATA Hello this is content ]]
Has anyone found a way or suggest a solution for the adapter to pass this type of XML file through?
I am trying to load an XML document into the database. I first read the XML document into a record structure, then I validate it against the XML schema to ensure its a valid XML.
At this point, I would like to load the contents of a recurring element into the database. The obvious solution would be to loop over this element and insert it into the database, however, that is a LOT of inserts!
Is there a better way to do this? What about the mapping of the XML to the database – is there some mapping document I can write to allow wM to automatically load the XML into the database? What are the best practices?
I’m afraid there’s no magic way for IS to automatically insert data into a database. You’ll need to loop and do inserts. You’ll want to control your commit/rollback behavior as appropriate to what you need to do (each insert can succeed/fail on its own? or does the group to succeed/fail as a group?). There are other threads on the forum covering how to control DB transactions.
Hi
I face a similar problem with the error message:
The field ‘PO_UPDATE_ID’ could not be found in the document.
But this happens very rarely, maybe, once a month. I am using enterprise server 4.1.1. Any idea why this could happen?