cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Richard Cunliffe" <rich...@cunliffe.net>
Subject RE: Cocoon and MySQL
Date Mon, 03 Feb 2003 14:29:14 GMT
Martin,

I have made your suggested changes and the web page still comes up
completely blank. Is there anything else I should be looking at?

Thanks,

Richard.


-----Original Message-----
From: holz@fiz-chemie.de [mailto:holz@fiz-chemie.de] 
Sent: 03 February 2003 14:02
To: cocoon-users@xml.apache.org
Subject: Re: Cocoon and MySQL

Hello Richard,


"Richard Cunliffe" <richard@cunliffe.net> writes:

> (logs attached)
> 
> Hi,
> 
> I have now got cocoon to start, and I have now put my pipeline in, but
> the page is coming up blank, when viewed through IE6.
> 
> My pipeline in the sitemap looks like this:
> 
> 
> <!-- soundpool Database (SQL) -->
> 
> <map:pipeline>
>             <map:match pattern="soundpool/database.html">
> 			<map:generate src="soundpool/database.xml"/>
> 			<map:transform type="sql">
> 			<map:parameter name="RICHARD"
> value="soundpool"/>
> 			</map:transform>
> 			<map:transform src="databasepc.xsl"/>
Do one step after the other -- disable the transformer
for testing or use labels.

> 			<map:serialize/>
>             </map:match>
> </map:pipeline>
> 
> 
> 
> I am unsure what should go under name="". I have assumed it's the
local
> host name given in mysql?

No, it is the name of the connection as defined in your cocoon.xconf.
My entry looks like this:

  <!-- Datasources: -->
   <datasources>
    <jdbc name="slide" logger="vsc.sql" > 
      <pool-controller min="2" max="6" />
      <auto-commit>true</auto-commit>
      <dburl>jdbc:postgresql://bog.fiz-chemie.de/slidestore</dburl>
      <user>slide</user>
      <password>geheim</password>
    </jdbc>
   </datasources>

So the parameter to the SQL Transformer is:
  <map:transform type="sql">
      <map:parameter name="use-connection" value="slide"/>
  </map:transform>
Remember to restart your servlet engine after changes to cocoon.xconf.

> 
> My web.xml looks like so:
Looks okay.

> 
> My database.xml looks like this:
> 
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <document>
> 	<text>soundpool</text>
> 	<title>the databse</title>
> 	<sql:execute-query xmlns:sql="http://apache.org/cocoon/SQL/2.0">
 	
> <sql:use-connection>localhost/soundpool</sql:use-connection>
You don't need this line.

> 		<sql:query>
> 			SELECT generalMusicTitle FROM album
> 		</sql:query>
> 	</sql:execute-query>
> </document>


--
Martin Holz                FIZ CHEMIE Berlin
<holz@fiz-chemie.de>  



---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <cocoon-users-unsubscribe@xml.apache.org>
For additional commands, e-mail:   <cocoon-users-help@xml.apache.org>




---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <cocoon-users-unsubscribe@xml.apache.org>
For additional commands, e-mail:   <cocoon-users-help@xml.apache.org>


Mime
View raw message