cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sven Beauprez" <Sven.Beaup...@xume.be>
Subject Re: SQLTransformer doesn´t output namespace prefixes?
Date Wed, 10 Oct 2001 20:03:24 GMT

Per-Olof ,

Personally, I prefer the first solution you propose:
(it will also be a little bit harder to implement :) )

<sql:output-namespace-usage type="set">
    <sql:uri>http://the.namespace.domain/path</sql:uri>
    <sql:prefix>sql</sql:prefix>
</sql:output-namespace-usage>

This means that if you have multiple queries in one xml document, you can configure the output

for them independently. And if you omit the sql:output-namespace element, no prefix is 
generated, like it should be...

Sven

On 9 Oct 2001 at 13:54, Per-Olof Norén wrote:

> Hello Tom and Sven,
> Thanx for answering my questions so fast, really helpful.
> I´d like some comments on my little design approach for the adjustments i
> need to make.
> 
> ----- Original Message -----
> From: "Sven Beauprez" <Sven.Beauprez@xume.be>
> To: <cocoon-dev@xml.apache.org>
> Sent: Monday, October 08, 2001 7:45 PM
> Subject: RE: SQLTransformer doesn´t output namespace prefixes?
> 
> >So the only reason why you need the sql-prefix again is when you want to
> > execute the sql-transformer again, - immediately - after the first one
> (this should mean you read
> > sql statements from the DB ?!? IMO a very rare case. This is - not - the
> same as in your case!).
> 
> Actually, I want to be able to feed the first stage with xml that is
> identical with the output of the first sql transformer, in the cmd
> namespace, ie using some sort of caching in the stage before, so only the
> exentqueries are ran.
> The issue really boils down to the fact that the transformer currently
> outputs namespace uri on the resulting elements and attributes and not
> including the prefix.
> I need to have the namespace configurable.
> 
> > So I strongly suggest you don't 'just forward' the sql prefix.
> .....
> > If you want to implement
> > this feature (which I encourage of course ;-) ), make it optional, so that
> if someone doesn't
> > configure the prefix, no prefix is added to resulting elements...
> 
> But the prefix used to call the transformer should IMO be outputted if the
> namespace is there. The prefix only serves as the visual proof that there is a
> namespace uri accociated with the elements and attributes, right. I agree on the
> use of options approach where the use of output namespace is configured
> something like this:
> 
> in the xml document
> 
> <sql:output-namespace-usage type="set">
>     <sql:uri>http://the.namespace.domain/path</sql:uri>
>     <sql:prefix>sql</sql:prefix>
> </sql:output-namespace-usage>
> or
> <sql:output-prefix-usage type="forward"/>
> or
> <sql:output-prefix-usage type="ignore"/>
> 
> or from the sitemap:
> 
> <map:transform type="sql">
>     <map:parameter name="output-namespace-usage" value="set"/>
> or
>     <map:parameter name="output-namespace-usage" value="forward"/>
> or
>     <map:parameter name="output-namespace-usage" value="ignore"/>
>     ...
> </map:transform>
> 
> > PS: it is true that i don't read the mailinglists that often anymore (new
> projects, new priorities),
> > but I will try to find some time the next few days to answer your
> questions...
> 
> thanx :-)
> 
> ps
> For those of you, like Tom, wonder about my strange name, firstname is
> Per-Olof :-)
> ds
> 
> Regards
> Per-Olof Norén
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> For additional commands, email: cocoon-dev-help@xml.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Mime
View raw message