You are viewing a plain text version of this content. The canonical link for it is here.
Posted to xindice-users@xml.apache.org by Pascal Maugeri <pa...@gmail.com> on 2007/06/07 09:45:11 UTC

Schema constraints

Hi

I have read in the user guide:

"This means it does not have any schema that constrains what can be
placed into a document collection."

Does it mean that the external app has the "responsability" to verify
the schema ?

Another question: how to search for XML documents that implement a
given XML schema ?

Regards,
Pascal

Re: Schema constraints

Posted by Pascal Maugeri <pa...@gmail.com>.
Thank you for your answer Vadim.

FYI, I would not dare to provide a patch to Xindice yet due to my poor
knowledge of Xindice itself and XML/XSD in general :-))) I will stick
for the time being to my role of humble user.

-pascal

On 6/7/07, Vadim Gritsenko <va...@reverycodes.com> wrote:
> Pascal Maugeri wrote:
> > I have read in the user guide:
> >
> > "This means it does not have any schema that constrains what can be
> > placed into a document collection."
> >
> > Does it mean that the external app has the "responsability" to verify
> > the schema ?
>
> Xindice does not care about DTDs or XSDs at the moment -- you can put any
> document you want. So if you want to validate the document against DTD or
> schema, do that before you store it in a database. Next version of Xindice might
> support validation -- and it will happen sooner if you provide a patch :)
>
> (Hmm... I'm not even sure you can put document with DTD into Xindice -- I recall
> the were some issues with it... Anybody else remembers?)
>
>
> > Another question: how to search for XML documents that implement a
> > given XML schema ?
>
> If it can be done via XPath [1], it should work in Xindice. I'm not sure though
> if it's possible.
>
> Vadim
>
> [1] http://www.w3.org/TR/xpath
>

Re: Schema constraints

Posted by Vadim Gritsenko <va...@reverycodes.com>.
Pascal Maugeri wrote:
> I have read in the user guide:
> 
> "This means it does not have any schema that constrains what can be
> placed into a document collection."
> 
> Does it mean that the external app has the "responsability" to verify
> the schema ?

Xindice does not care about DTDs or XSDs at the moment -- you can put any 
document you want. So if you want to validate the document against DTD or 
schema, do that before you store it in a database. Next version of Xindice might 
support validation -- and it will happen sooner if you provide a patch :)

(Hmm... I'm not even sure you can put document with DTD into Xindice -- I recall 
the were some issues with it... Anybody else remembers?)


> Another question: how to search for XML documents that implement a
> given XML schema ?

If it can be done via XPath [1], it should work in Xindice. I'm not sure though 
if it's possible.

Vadim

[1] http://www.w3.org/TR/xpath