You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by "Schmitz, Jeffrey A" <Je...@boeing.com> on 2007/08/14 23:06:40 UTC

esql

Hello,
   I'm trying to get esql query to work within my xsp page, but am
having no luck.  I don't get any errors, but I don't get any data
either, and also the no-results tag doesn't get invoked, nor does the
get-message tag.  It looks pretty simple, but with no results and no
error messages to go by, I'm pretty much at a loss.  I've pasted the
applicable entries in my cocoon.xconf file, along with my xsp page
below.  Note that the greeting logic sheet part of the xsp is working.
Any help would be appreciated.

Thanks,
Jeff

Cocoon.xconf:
  <builtin-logicsheet>
          <parameter name="prefix" value="esql"/>
          <parameter name="uri"
value="http://apache.org/cocoon/SQL/v2"/>
          <parameter name="href"
value="resource://org/apache/cocoon/components/language/markup/xsp/java/
esql.xsl"/>
  </builtin-logicsheet>


  <datasources>
    
    <jdbc name="SIF">
      <pool-controller min="5" max="10"/>
      <dburl>jdbc:mysql://localhost/ivhm</dburl>
      <user>ivhm</user>
      <password>ivhm</password>
    </jdbc>
    
  </datasources>

Greeting3.xsp:

<?xml version="1.0"?>
<?xml-logicsheet href="logicsheet.greeting.xsl"?>

<xsp:page xmlns:xsp="http://apache.org/xsp"
          xmlns:greeting="http://duke.edu/tutorial/greeting"
          xmlns:esql="http://apache.org/cocoon/SQL/v2">
  <greeting>
    <greeting:hello-world/>
  </greeting>
  <esql:connection>
    <esql:pool>SIF</esql:pool>
    <esql:execute-query>
      <esql:query>SELECT Name FROM myTable</esql:query>
        <esql:results>
          <table>
            <esql:row-results>
              <tr>
                <td><esql:get-string column="Name"/></td>
              </tr>
            </esql:row-results>
          </table>
    </esql:results>
    <esql:no-results>
       <p>Sorry, no results!</p>
    </esql:no-results>

      <esql:error-results>
        <P><esql:get-message/>    </P> 
      </esql:error-results>
     
    
  </esql:execute-query>
</esql:connection>


</xsp:page>

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