I won't argue against redoing the design ;-), but prototyping with JSP can be
easier and quicker than servlets/MVC/Java classes. If you still want to pursue
the JSP/JSTL route, I'd first try to simplify the page so you're sure the SQL
piece is working. Then, gradually add stuff in so you can tell exactly which
part of the page is causing the problem.

Quoting Peter Choe <[EMAIL PROTECTED]>:

> no error is being reported but the jsp doesn't finish rendering.  but i 
> guess i should redo the design.  i was just trying to be lazy and avoid 
> coding.
> 
> thanks all.
> 
> Kris Schneider wrote:
> 
> >You're not really embedding one <sql:query> within another, but it should
> work.
> >What type of error(s) are you getting?
> >
> >Quoting Peter Choe <[EMAIL PROTECTED]>:
> >
> >  
> >
> >>is it possible to embed a <sql:query> tag inside a <sql:query>?
> >>
> >>i am trying to use the result of one sql to look up data with another
> sql:
> >>
> >><sql:query var="waitList" sql="SELECT discipline, course_num, 
> >>days_of_week, time_slot, crs_id, is_available, wait_list_course.semester 
> >>FROM wait_list_course, time_slots WHERE 
> >>time_slots.time_id=wait_list_course.time_id AND school_id=? ORDER BY 
> >>discipline, course_num, time_slot, is_available">
> >><sql:param value="${sessionScope.school}" />
> >></sql:query>
> >><c:forEach var="listRec" items="${waitList.rows}">
> >><tr><td><c:out value="${listRec.discipline}" /> <c:out 
> >>value="${listRec.course_num}" /></td><td><c:out 
> >>value="${listRec.days_of_week}" /></td><td><c:out 
> >>value="${listRec.time_slot}" /></td><td><c:out 
> >>value="${listRec.is_available}" /></td><td><c:out 
> >>value="${listRec.semester}" /></td>
> >><sql:query var="count" sql="SELECT count(*) FROM student_status WHERE 
> >>add IS NOT NULL AND crs_id=?">   
> >><sql:param value="${listRec.crs_id}" />
> >></sql:query>   
> >><td><c:forEach var="act_count" items="${count.rowsByIndex}"><c:out 
> >>value="${act_count[0]}" /></c:forEach></td>       
> >><td><input type="button" name="close" value="Close" 
> >>onClick="doAction('<c:out value="${listRec.crs_id}" />', 'close', 
> >>'No')"><input type="button" name="open" value="Open" 
> >>onClick="doAction('<c:out value="${listRec.crs_id}" />', 'close', 
> >>'Yes')"><input type="button" name="recycle" value="Recycle" 
> >>onClick="doAction('<c:out value="${listRec.crs_id}" />',
> 'recycle')"></tr>
> >></c:forEach>

-- 
Kris Schneider <mailto:[EMAIL PROTECTED]>
D.O.Tech       <http://www.dotech.com/>

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

Reply via email to