yes, I want to tokenize the strring returned from the database using DBtag :
StringTokenizer st = new StringTokenizer(<sql:getColumn position="6"/>);

But Why it does not work ???



>From: Chris Pratt <[EMAIL PROTECTED]>
>Reply-To: A mailing list about Java Server Pages specification and
>reference <[EMAIL PROTECTED]>
>To: [EMAIL PROTECTED]
>Subject: Re: DBtag with StringTokenizer ??
>Date: Mon, 22 Oct 2001 09:31:50 -0700
>
>All the constructors for StringTokenizer require a parameter.  You have to
>tell it what to tokenize.
>     (*Chris*)
>
>----- Original Message -----
>From: "sufi malak" <[EMAIL PROTECTED]>
>To: <[EMAIL PROTECTED]>
>Sent: Monday, October 22, 2001 6:51 AM
>Subject: Re: [JSP-INTEREST] DBtag with StringTokenizer ??
>
>
> > Here is ther error I got :
> >
> > Error: 500
> > Location: /abovebeyond/ThisMonth.jsp
> > Internal Servlet Error:
> >
> > org.apache.jasper.JasperException: Unable to compile class for
> >
>JSPC:\tomcat323\work\localhost_8080%2Fabovebeyond\_0002fThisMonth_0002ejspTh
>isMonth_jsp_33.java:321:
> > Missing term.
> >                                   StringTokenizer st = new
>StringTokenizer();
> >
>^
> >
>C:\tomcat323\work\localhost_8080%2Fabovebeyond\_0002fThisMonth_0002ejspThisM
>onth_jsp_33.java:321:
> > ')' expected.
> >                                   StringTokenizer st = new
>StringTokenizer();
> >
> >   ^
> > 2 errors
> >
> >
> >
> >
> > >From: sufi malak <[EMAIL PROTECTED]>
> > >Reply-To: A mailing list about Java Server Pages specification and
> > >reference <[EMAIL PROTECTED]>
> > >To: [EMAIL PROTECTED]
> > >Subject: DBtag with StringTokenizer ??
> > >Date: Mon, 22 Oct 2001 13:40:20 +0000
> > >
> > >Hi, I am using DBtag in tomcat with Mysql, one of the fields of a table
>in
> > >the database is a TEXT field, I want to display only the three first
>word
> > >of
> > >that field as a link, here is what I did :
> > >
> > ><sql:preparedStatement id="stmt6" conn="conn1">
> > >  <sql:query>
> > >    select * from reward
> > >  </sql:query>
> > >  <sql:resultSet id="rset4">
> > >
> > >   <%
> > >          StringTokenizer st = new StringTokenizer(<sql:getColumn
> > >position="6"/>);
> > >          StringBuffer sb = new StringBuffer();
> > >          int i = 0;
> > >          while (st.hasMoreTokens()) {
> > >          if (i >= 3)
> > >          break;
> > >          i++;
> > >          sb.append(st.nextToken());
> > >          }
> > >          %>
> > >  <pg:item>
> > >    <tr bgcolor="#eeeeff">
> > >      <td><sql:getColumn position="2"/></td>
> > >      <td><sql:getColumn position="6"/></td>
> > >      <td> <a href="nominee.jsp"> <%= sb %></a></td>
> > >    </tr>
> > >  </pg:item>
> > >  </sql:resultSet>
> > >
> > >Please could you tell me what's wrong here ?
> > >
> > >_________________________________________________________________
> > >Get your FREE download of MSN Explorer at
>http://explorer.msn.com/intl.asp
> > >
> >
> >===========================================================================
> > >To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> > >JSP-INTEREST".
> > >For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
> > >DIGEST".
> > >Some relevant FAQs on JSP/Servlets can be found at:
> > >
> > >http://archives.java.sun.com/jsp-interest.html
> > >http://java.sun.com/products/jsp/faq.html
> > >http://www.esperanto.org.nz/jsp/jspfaq.jsp
> > >http://www.jguru.com/faq/index.jsp
> > >http://www.jspinsider.com
> >
> >
> > _________________________________________________________________
> > Get your FREE download of MSN Explorer at
>http://explorer.msn.com/intl.asp
> >
> >
>===========================================================================
> > To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
>JSP-INTEREST".
> > For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
>DIGEST".
> > Some relevant FAQs on JSP/Servlets can be found at:
> >
> >  http://archives.java.sun.com/jsp-interest.html
> >  http://java.sun.com/products/jsp/faq.html
> >  http://www.esperanto.org.nz/jsp/jspfaq.jsp
> >  http://www.jguru.com/faq/index.jsp
> >  http://www.jspinsider.com
>
>
>_________________________________________________________
>Do You Yahoo!?
>Get your free @yahoo.com address at http://mail.yahoo.com
>
>
>===========================================================================
>To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
>JSP-INTEREST".
>For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
>DIGEST".
>Some relevant FAQs on JSP/Servlets can be found at:
>
>  http://archives.java.sun.com/jsp-interest.html
>  http://java.sun.com/products/jsp/faq.html
>  http://www.esperanto.org.nz/jsp/jspfaq.jsp
>  http://www.jguru.com/faq/index.jsp
>  http://www.jspinsider.com


_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://archives.java.sun.com/jsp-interest.html
 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.jsp
 http://www.jguru.com/faq/index.jsp
 http://www.jspinsider.com

Reply via email to