STRUTS中JSP页面读取request的问题
在STRUTS中我将查询数据库的值在ACTION中保存在request中如:
request.setAttribute("clientname", OrderList.getClientName());
request.setAttribute("invoiceno", OrderList.getInvoiceNo());
然后在JSP页面中用<bean:write name="clientname">读取
如果数据库里得到的值为<NULL>的话,JSP页面会报错:
javax.servlet.ServletException: Cannot find bean clientname in any scope
这是怎么回事呢?如何解决这样的问题,望各位大侠帮帮小弟,在此先谢了!