Hello, there is a problem. Preambula: I try to design a solution for on-line integration between Siebel an Navision. What i have got: All the solutinon is based on events. In Navision we create two tables: EventsNav & EventsSiebel, for events from Navision and Siebel resp. Siebel can read/write data to another MS SQL-database table. So Siebel will read/write events to tables in Navision database created by Navision. We want to use XML as data format. So how could we store large XML data if Navision’s largest txt field size is 1024 bytes. Maybe BLOB field can work? So the queston is how to work with XML stored in BLOB in Navision. Thanx for advice.
Maybe something like this would work:
xmlInStream is type InStream; DOMDoc is type Automation, ‘Microsoft XML, v4.0’.DOMDocument;
EventsSiebel.LOCKTABLE; IF EventsSiebel.FIND('-') THEN BEGIN EventsSiebel.CALCFIELDS(xmlBlobField); IF EventsSiebel.xmlBlobField.HASVALUE THEN BEGIN EventsSiebel.xmlBlobField.CREATEINSTREAM(xlmInStream); CREATE(DOMDoc); DOMDoc.async := FALSE; IF DOMDoc.Load(xmlInStream) THEN BEGIN // do stuff with the xml in DOMDoc... END; END; EventsSiebel.DELETE; COMMIT; END;
Thanx a lot - all works fine!