Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.
#Automation
Hi all,I’m using Tamino 4.1.4.1, the question is:is possible to store in a single collection these xml instances:If this is possible how should I define the schema?Regards,Gx
Hi Gx,yes, this is possible. You need a separate schema for each doctype, because one schema cannot define elements from different namespaces. The schemas look like:<?xml version = "1.0" encoding = "UTF-8"?><xs:schema targetNamespace = “B” xmlns:B = “B” xmlns:tsd = “http://namespaces.softwareag.com/tamino/TaminoSchemaDefinition” xmlns:xs = “XML Schema”> xs:annotation xs:appinfo <tsd:schemaInfo name = “TESTB”> <tsd:collection name = “TEST”></tsd:collection> <tsd:doctype name = “B:TEST”> tsd:logical tsd:contentclosed</tsd:content> </tsd:logical> </tsd:doctype> </tsd:schemaInfo> </xs:appinfo> </xs:annotation> <xs:element name = “TEST” type = “xs:string”></xs:element></xs:schema><?xml version = "1.0" encoding = "UTF-8"?><xs:schema targetNamespace = “B” xmlns:B = “B” xmlns:tsd = “http://namespaces.softwareag.com/tamino/TaminoSchemaDefinition” xmlns:xs = “XML Schema”> xs:annotation xs:appinfo <tsd:schemaInfo name = “TESTB”> <tsd:collection name = “TEST”></tsd:collection> <tsd:doctype name = “B:TEST”> tsd:logical tsd:contentclosed</tsd:content> </tsd:logical> </tsd:doctype> </tsd:schemaInfo> </xs:appinfo> </xs:annotation> <xs:element name = “TEST” type = “xs:string”></xs:element></xs:schema>and<?xml version = "1.0" encoding = "UTF-8"?><xs:schema targetNamespace = “A” xmlns:A = “A” xmlns:tsd = “http://namespaces.softwareag.com/tamino/TaminoSchemaDefinition” xmlns:xs = “XML Schema”> xs:annotation xs:appinfo <tsd:schemaInfo name = “TEST”> <tsd:collection name = “TEST”></tsd:collection> <tsd:doctype name = “A:TEST”> tsd:logical tsd:contentclosed</tsd:content> </tsd:logical> </tsd:doctype> </tsd:schemaInfo> </xs:appinfo> </xs:annotation> <xs:element name = “TEST” type = “xs:string”></xs:element></xs:schema>Note that for the insertion of documents it does not matter which prefix you define in a schema.Having these schemas defined, you can insert the two TEST instances you have.RegardsHarald