batchloading data where schemaUsage is optional

it doesn’t seem possible to use inoload to load data into a collection where schemaUsage has been defined as optional with tamino x-plorer, because inoload wants both a collection and a doctype. i have no problem using the interactive interface to do this, but since i want to batchload some documents, i tried hacking xqlinp.htm to change the method from “post” to “get” as a workaround. this works up to a point, but i consistently get the error message, Document not well-formed, with ino:returnvalue=“8711”, ino:code=“INOXPE8711”, and the additional message, Line 1, Column 1: Invalid document structure. however, these documents load fine when using “post” (i.e., using the original form). is there a way to successfully batchload documents into a collection where schemaUsage has been defined as optional?

thanks.

in answer to my own question, two things.

if i load one document with tamino x-plorer, then i get rootElement name (in lieu of doctype name) for that document. once that happens, i can then batch load the rest of the documents using inoload and the collection/doctype argument.

however, before i tried this, i tried using the simplest doctype in order to define a schema so that i could use inoload without workarounds, (where “foo” stands for the actual root element of the documents i want to load), but x-plorer doesn’t like defining schemas from that kind of dtd, so that didn’t work.

one thing to note is that in using this method, ino:id’s are assigned beginning 1024 and in increments of 1024 (so the second id assigned is 2048). i hope i don’t run out of ino:id’s in the process of loading lots of records this way.

I would generally expect ino:ids to allocated for each document loaded. You don’t have 1024 elements in the documents you are loading do you?

The documentation under the The Tamino Data Loader provides another way of doing this. It specifies a multi document load format:

<?xml version="1.0" encoding="utf-8"?>
<ino:request xmlns:ino="http://namespaces.softwareag.com/tamino/response2">

<ino:object [ino:docname="docname"]  [ino:id="id"] >
    <!-- document contents for first XML document including PI's and Comments -->
</ino:object >

<ino:object [ino:docname="docname"] [ino:id="id"] >
    <!-- document contents for second XML document including PI's and Comments -->
</ino:object >
        .....
</ino:request>
</pre><BR><BR>I think that this should work to a schemas optional collection. One of my test collection is defined using:<BR><BR><pre class="ip-ubbcode-code-pre">
<?xml version="1.0" encoding="utf-8"?>
<tsd:collection name="schemasOptional" xmlns:tsd="http://namespaces.softwareag.com/tamino/TaminoSchemaDefinition">
	<tsd:schema use="optional"/>
</tsd:collection>

it is correct that mass load (without the concurrentwrite option, think) allocates the first ino:id as a multiple of 1024. This is for internal optimization reasons adn shouldn’t hurt too much (you still can do millions of small mass loads before ino:ids are exhausted)

Regards

Harald