Hi,

what is required to get the http request parameter to work? I have
----------------------------
[...]
<xsp:page language="java"
          xmlns:xsp="http://www.apache.org/1999/XSP/Core";
          xmlns:esql="http://apache.org/cocoon/SQL/v2";
          xmlns:request="http://www.apache.org/1999/XSP/Request";  <<---HERE
>
[...]

    <esql:query>
      select name as reg_name,
             deviceID as reg_deviceID,
             description as reg_description,
             startTime as reg_startTime,
             endTime as reg_endTime
      from user, terminal, deviceType, registration
      where terminal.userID = <request:get-parameter name="userID"/>
<<---HERE
            and user.userID = terminal.userID
            and deviceType.deviceType = terminal.deviceType
            and registration.terminalID = terminal.terminalID;
    </esql:query>
[...]

As far as I have understood, I can then put 
------------
?userID=123456 
------------
at the end of the url, e.g. 
-------------
http://localhost/welcome.xml?userID=123456

and 123456 will be used. But it's not working, so I guess I'll have to add
something somewhere? I don't get any error messages, but I don't get any
data from the query either. The query works when I use

---
<!ENTITY userID "123456"> //(in the DTD)

[...]

and terminal.userID = &userID; //(in the query)
-------

I'm using Cocoon 1.8.2

/Anne Marie




-----Original Message-----
From: JEULIN Olivier [mailto:[EMAIL PROTECTED]]
Sent: 31. juli 2001 13:26
To: '[EMAIL PROTECTED]'
Subject: RE: Connecting database and XML pages


[...]

          <esql:query>
                select b.ref as ref b.quantite as nb
                from basket b
                where b.id = <request:get-parameter name="fragResultID"/>
<!-- using a HTTP req. param. -->
          </esql:query>
        

[more ...]

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

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>

Reply via email to