Data Insert Problems..

is there any mechanism to avoid redundant datas being inserted into Tamino?

or have to apply it by programmer himself on application level?
:rolleyes: :rolleyes: :rolleyes:

I am a Java NewComer.

What do you mean with redundant data?
Several times the same XML document?
Several XML document, which contain some equal fields?
Please explain in more detail.


the ‘No’ attribute should be unique in this class and in the XML “Table”.

what should I do?Same as working with MS-SQL —defining a primary key and waiting db to throw an error?

Hi there.

What will your Tamino schema look like?
Will you be inserting multiple Class documents, which contain multiple Student elements?

As far as I know, there is no way to define a Primary Key / Unique Constraint in Tamino at the moment.
The documents stored into Tamino can be given a “name” though - using the ino:docname attribute.
Uniqueness is guaranteed on ino:docname - if you try to insert a document with a name that is used in an existing document, Tamino returns an error.

This would require that you write some application logic to check the uniqueness of the “No” attribute within the Class document, then use the value of the “No” attribute as the value of ino:docname for insert.

I hope that helps,

:wink: :wink: :wink:

I am a Java NewComer.


I am a Java NewComer.