cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Yves Vindevogel <yves.vindevo...@implements.be>
Subject Re: ESQL: "execute-query" ignored by cocoon!!!
Date Thu, 10 Apr 2003 13:52:16 GMT
And you need to create a root element where your data is put in ....
And don't forget to mention the connection pool either.

Something like this

<?xml version="1.0" encoding="ISO-8859-1"?>

    <xsp:page language="java"
    			xmlns:xsp="http://apache.org/xsp"
			xmlns:esql="http://apache.org/cocoon/SQL/v2"
			xmlns:xsp-request="http://apache.org/xsp/request/2.0"
			xmlns:xsp-session="http://apache.org/xsp/session/2.0"
			create-session="true">

        <html>

            <esql:connection>
                <esql:pool>pierrefabre</esql:pool>

                <esql:execute-query>
			<esql:query>
				select * from tblLogin
                                	where name = '<xsp-request:get-parameter 
name="username"/>'
                                 	and password = '<xsp-request:get-parameter 
name="password"/>' ;
			</esql:query>

                    <esql:results>
				:-))
                    </esql:results>

		    <esql:no-results>
		            	<head>
            			</head>

				<body>
					;-((
				</body>
		    </esql:no-results>
                </esql:execute-query>

            </esql:connection>
	</html>
    </xsp:page>


> On czw, kwi 10, 2003 at 02:30:57 +0200, Maxime.Gheysen@swisscom.com wrote:
> > I don't know why, but in all my pages, all the following queries are
> > simply ignored!!!! Cocoon just jump over it! in SQL Profiler I see all
> > queries, like "select * from Status", "select * from Groups", but not
> > following! Is it maybe because of a conflict with the session variable
> > "user"?
> >
> > 	 <esql:execute-query>
> > 		<esql:query>
> > 			select ur_name from Users
> > 	    </esql:query>
> > 		<esql:results>
> > 		  <esql:row-results>
> > 			<option><esql:get-string
> > column="ur_name"/></option>
> > 		  </esql:row-results>
> > 		</esql:results>
> > 	  </esql:execute-query>
>
> Is the piece of code you provided enclosed with <esql:connection> tag ?
> 	ouzo

-- 
Met vriendelijke groeten,
Kind regards,
Bien à vous,

Yves Vindevogel

Implements
Kempische Steenweg 206  --  3500 Hasselt  --  Belgium
Phone/Fax: +32 (11) 43.55.76  --  Mobile: +32 (478) 80.82.91
Mail: yves.vindevogel@implements.be  --  www.implements.be

Quote: The winner never says participating is more important than winning.

---------------------------------------------------------------------
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