You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Drasko Kokic <dr...@yahoo.com> on 2000/11/27 11:45:49 UTC

ESQL schema

--- Donald Ball <ba...@webslingerZ.com> wrote:
> the correct schema for the esql logicsheet is
> "documented" in the
> logicsheet itself - the schema lags behind the
> actual logicsheet because
> i've never written one before and no one has
> volunteered to help me. if
> you have expertise in this area, i'd love it if i
> could describe to you in
> words what's allowed and have you help me fix the
> schema.
> 
> - donald
> 

okay ... I would love to help you in this efort.

drasko

__________________________________________________
Do You Yahoo!?
Yahoo! Shopping - Thousands of Stores. Millions of Products.
http://shopping.yahoo.com/

Re: ESQL schema

Posted by Donald Ball <ba...@webslingerZ.com>.
On Mon, 27 Nov 2000, Paul Russell wrote:

> On Mon, Nov 27, 2000 at 01:51:59PM -0500, Donald Ball wrote:
> > On Mon, 27 Nov 2000, Drasko Kokic wrote:
> > 
> > > okay ... I would love to help you in this efort.
> > 
> > the big trouble i'm having now is trying to figure out how to state that
> > underneath esql:row-results, you can have text, elements from other
> > namespaces, and a specific set of elements from the esql namespace, in
> > arbitrary order, as many times as you like. i would have thought that the
> > schema 'all' element would be part of the solution, but from what i read
> > in the primer last night, it doesn't seem to work. got any suggestions?
> 
> <xsd:type name="ESQLResults" mixed="yes">
> 	<xsd:sequence>
> 		<xsd:choice>
> 			<xsd:element ref="esql-get-foo"/>
> 			<!-- other elements here -->
> 		</xsd:choice>
> 	</xsd:sequence>
> </xsd:type>
> 
> Will do the text and various ESQL tags, but I must admit, I
> can't remember how to say 'any other element here' :/

ooh, that's a clever one, i hadn't thought of that. i wonder why xml
schema doesn't just have an <xsd:set> element though? anyway, i think this
might work:

<element name="esql:row-results" minOccurs="0" maxOccurs="1">
  <complexType mixed="true">
    <sequence>
      <choice>
        <any namespace="##other" minOccurs="0" maxOccurs="unbounded"
          processContents="lax"/>
        <element name="esql:get-columns" minOccurs="0" maxOccurs="unbounded"/>
        <element name="esql:get-string" minOccurs="0" maxOccurs="unbounded"/>
      </choice>
    </sequence>
  </complexType>
</element>

although, i must admit, i'm not sure how to declare the "target namespace
of the type being defined". anyone?

next biggie - i've got some declarations like this:

<element name="esql:driver" type="string"/>

but, as we all know, it's not mandatory that this be an XML string, just
that it be an XSP expression that will resolve to be a string at
runtime. anyone got any clever ideas on how to do that? my best thought so
far is to allow it to contain anything _except_ xsp:logic elements. not a
perfect test, but it might be the best we can do. any ideas?

you know one thing that's really confusing about xml schema? schema
elements aren't necessarily xml elements, they might be composed of many
xml elements. i do wish they'd chosen a different name.

- donald


Re: ESQL schema

Posted by Donald Ball <ba...@webslingerZ.com>.
On Mon, 27 Nov 2000, Paul Russell wrote:

> On Mon, Nov 27, 2000 at 01:51:59PM -0500, Donald Ball wrote:
> > On Mon, 27 Nov 2000, Drasko Kokic wrote:
> > 
> > > okay ... I would love to help you in this efort.
> > 
> > the big trouble i'm having now is trying to figure out how to state that
> > underneath esql:row-results, you can have text, elements from other
> > namespaces, and a specific set of elements from the esql namespace, in
> > arbitrary order, as many times as you like. i would have thought that the
> > schema 'all' element would be part of the solution, but from what i read
> > in the primer last night, it doesn't seem to work. got any suggestions?
> 
> <xsd:type name="ESQLResults" mixed="yes">
> 	<xsd:sequence>
> 		<xsd:choice>
> 			<xsd:element ref="esql-get-foo"/>
> 			<!-- other elements here -->
> 		</xsd:choice>
> 	</xsd:sequence>
> </xsd:type>
> 
> Will do the text and various ESQL tags, but I must admit, I
> can't remember how to say 'any other element here' :/

ooh, that's a clever one, i hadn't thought of that. i wonder why xml
schema doesn't just have an <xsd:set> element though? anyway, i think this
might work:

<element name="esql:row-results" minOccurs="0" maxOccurs="1">
  <complexType mixed="true">
    <sequence>
      <choice>
        <any namespace="##other" minOccurs="0" maxOccurs="unbounded"
          processContents="lax"/>
        <element name="esql:get-columns" minOccurs="0" maxOccurs="unbounded"/>
        <element name="esql:get-string" minOccurs="0" maxOccurs="unbounded"/>
      </choice>
    </sequence>
  </complexType>
</element>

although, i must admit, i'm not sure how to declare the "target namespace
of the type being defined". anyone?

next biggie - i've got some declarations like this:

<element name="esql:driver" type="string"/>

but, as we all know, it's not mandatory that this be an XML string, just
that it be an XSP expression that will resolve to be a string at
runtime. anyone got any clever ideas on how to do that? my best thought so
far is to allow it to contain anything _except_ xsp:logic elements. not a
perfect test, but it might be the best we can do. any ideas?

you know one thing that's really confusing about xml schema? schema
elements aren't necessarily xml elements, they might be composed of many
xml elements. i do wish they'd chosen a different name.

- donald


Re: ESQL schema

Posted by Paul Russell <pa...@luminas.co.uk>.
On Mon, Nov 27, 2000 at 01:51:59PM -0500, Donald Ball wrote:
> On Mon, 27 Nov 2000, Drasko Kokic wrote:
> 
> > okay ... I would love to help you in this efort.
> 
> the big trouble i'm having now is trying to figure out how to state that
> underneath esql:row-results, you can have text, elements from other
> namespaces, and a specific set of elements from the esql namespace, in
> arbitrary order, as many times as you like. i would have thought that the
> schema 'all' element would be part of the solution, but from what i read
> in the primer last night, it doesn't seem to work. got any suggestions?

<xsd:type name="ESQLResults" mixed="yes">
	<xsd:sequence>
		<xsd:choice>
			<xsd:element ref="esql-get-foo"/>
			<!-- other elements here -->
		</xsd:choice>
	</xsd:sequence>
</xsd:type>

Will do the text and various ESQL tags, but I must admit, I
can't remember how to say 'any other element here' :/

P.

-- 
Paul Russell                               <pa...@luminas.co.uk>
Technical Director,                   http://www.luminas.co.uk
Luminas Ltd.

Re: ESQL schema

Posted by Donald Ball <ba...@webslingerZ.com>.
On Mon, 27 Nov 2000, Drasko Kokic wrote:

> okay ... I would love to help you in this efort.

the big trouble i'm having now is trying to figure out how to state that
underneath esql:row-results, you can have text, elements from other
namespaces, and a specific set of elements from the esql namespace, in
arbitrary order, as many times as you like. i would have thought that the
schema 'all' element would be part of the solution, but from what i read
in the primer last night, it doesn't seem to work. got any suggestions?

- donald


Re: ESQL schema

Posted by Donald Ball <ba...@webslingerZ.com>.
On Mon, 27 Nov 2000, Drasko Kokic wrote:

> okay ... I would love to help you in this efort.

the big trouble i'm having now is trying to figure out how to state that
underneath esql:row-results, you can have text, elements from other
namespaces, and a specific set of elements from the esql namespace, in
arbitrary order, as many times as you like. i would have thought that the
schema 'all' element would be part of the solution, but from what i read
in the primer last night, it doesn't seem to work. got any suggestions?

- donald