[
Lists Home |
Date Index |
Thread Index
]
Note that XML Schema (and Relax NG for that matter) is more of a
constraint system than just a static type system. Thus there are many
constraints in XML Schema that XQuery's static type system will not be
able to check. But it will be able to statically check structural
constraints such as that a function only takes Employees and not Dogs
etc.
Best regards
Michael
> -----Original Message-----
> From: Dare Obasanjo [mailto:kpako@yahoo.com]
> Sent: Friday, January 04, 2002 8:05 AM
> To: Champion, Mike; www-xml-query-comments@w3.org;
xml-dev@lists.xml.org;
> Jonathan Robie
> Cc: suciu@cs.washington.edu
> Subject: Re: [xml-dev] The use of XML syntax in XML Query
>
> ----- Original Message -----
> From: "Jonathan Robie" <jonathan.robie@softwareag.com>
> To: "Dare Obasanjo" <kpako@yahoo.com>; "Champion, Mike"
> <Mike.Champion@SoftwareAG-USA.com>; <www-xml-query-comments@w3.org>;
> <xml-dev@lists.xml.org>
> Cc: <suciu@cs.washington.edu>
> Sent: Thursday, January 03, 2002 4:26 PM
> Subject: Re: [xml-dev] The use of XML syntax in XML Query
>
> > 2. Typechecking without type inference can work fine as long as you
do
> not
> > have joins. If joins are involved, typechecking becomes undecidable.
>
> So what happens with XQuery joins (
http://www.w3.org/TR/xquery/#id-joins
> )
> then? Will there be a caveat in the recommendation that indicates that
> static
> typechecking can't be done w.r.t joins?
>
> > 3. Type inference is the most promising approach, but it does lead
to
> some
> > false negatives. He gives an example using a content model involving
> equal
> > cardinality among three different elements in sequence. The schema
for
> this
> > can not be expressed in DTDs or in XML Schema, so it is not clear to
me
> > that this is a real limitation, but I just read this, and I need to
do
> some
> > thinking before I would want to draw a strong conclusion based on
his
> > examples.
>
> But his example is fairly simple and utilizes none of the really
complex
> abilities of XML schemas. For instance, how can static typechecking
work
> for
> schemas that use identity constraints like xs:unique? I fail to see
how
> one
> can guarantee that the following expression
>
> f = <results>
> FOR $x in /employee/age
> RETURN
> <employee-id>{
> $x * 13
> }</employee-id>
> </results>
>
> will only return unique values for <employee-id> via type inference.
>
> > 4. Dan concludes that type inference is still the most promising
> approach
> > to static typechecking, but that further work needs to be done on
its
> > applicability and limitations.
> >
> > My own take on this is that static type checking using type
inference is
> > very promising, and seems to work well in theory for the kinds of
> queries I
> > have looked at. An implementation using the current type system did
> catch
> > interesting errors for me. I think our type system needs further
work,
> and
> > we need more practical experience using implementations that do
static
> type
> > checking. This is one of the highest priorities for me personally.
>
> I'm interested in the type of queries you've looked at. I'm not
convinced
> that
> this is as straightforward a problem as you've implied but readily
admit
> that
> my theoretical CS skills are nowhere near excellent so you may be
right
> and
> all I need is a little convincing.
>
> --
> THINGS TO DO IF I BECOME AN EVIL OVERLORD #35
> I will not grow a goatee. In the old days they made you look diabolic.
Now
> they just make you look like a disaffected member of Generation X.
>
>
>
> _________________________________________________________
>
> Do You Yahoo!?
>
> Get your free @yahoo.com address at http://mail.yahoo.com
>
>
>
>
> -----------------------------------------------------------------
> The xml-dev list is sponsored by XML.org <http://www.xml.org>, an
> initiative of OASIS <http://www.oasis-open.org>
>
> The list archives are at http://lists.xml.org/archives/xml-dev/
>
> To subscribe or unsubscribe from this list use the subscription
> manager: <http://lists.xml.org/ob/adm.pl>
|