Re: String size in a schema

Subject: Re: String size in a schema
From: Eric van der Vlist <vdv@xxxxxxxxxxxx>
Date: Thu, 30 Nov 2000 16:56:59 +0100
An't you confusing the XSLT and W3C XML Schema "attribute" elements that
are 2 absolutely different stuff (and a good illustration of what the
namespaces are used for) ?

I guess that you want to define a W3C XML Schema attribute and I'll try
to answer even though it's off topic on a XSL list...

A construct for define an attribute that is a string with less than 30
characters is:

<xsd:attribute name="products">
   <xsd:restriction base="xsd:string">
    <xsd:maxLength value="30"/>
</xsd:attribute >

Hope this helps,


David Delgranche wrote:
> Hi
> I'm writing an XSLT stylesheet to create a SQL script from a schema. I
> have read the XMLschema part 0 specifications but I still have a
> question. I would like to be able to declare attribute or element typed
> as a string but with specifying the maximum length... I would like
> something like:
> <xsl:attribute name="products" type="xsd:string" maxlength="30"/>
> It seems that facets could help me. I had a look at the documentation on
> them but there is no implementation example.. Does anyone know how to
> use them?
> Thankes a lot for help
> David
> --
> Silicom Region Ouest
> 80 av des Buttes de Coesmes 35700 RENNES
> Tel: 02 99 84 17 17
>  XSL-List info and archive:

See you at XML 2000
Eric van der Vlist       Dyomedea              

 XSL-List info and archive:

Current Thread