(However, I am connected to an Oracle Database, not MySQL).
I did a similar setup/deployment on glassfish-4.1 and did not get these issues. It worked there.
If I remove these tags from the jsp file then the errors go away but then I wont get the data displayed from the database.
below is the entire jsp code
Below is the errors:
J. Kevin Robbins wrote:And btw, using the SQL tags is a Bad Idea except for rapid prototyping. Never do that for production code. Move that database code to a DAO and use a PreparedStatement.
Will keep that in mind. Will try that after getting this test project to work.
I have managed to add the libraries as requested to the project so the error is no longer there.
However I am still getting these errors:
I have added the following jar file to my library but still giving errors:
C:\Program Files\Apache Software Foundation\Apache Tomcat 8.0.9\lib\jstl-1.1.2.jar
Should URI link change?
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@taglib prefix="sql" uri="http://java.sun.com/jsp/jstl/sql"%>
Look up info for JSTL 1.2 and make sure you have the right jar files. Using the wrong versions will cause no end of frustrating and hard to debug problems whose error messages will be completely unhelpful.
Do this before you do anything else because nothing is going to work until you do.
Bear Bibeault wrote:Your URIs are for very very old versions of the JSTL from JSP1.x. Are you sure that's what you want to use?
These look fine to me. They have the /jsp/ section in them which was the difference between JSTL1.0 and JSTL1.1.
I didn't think the URI changed after that.
The error message seems to be coming from an Ant build file - presumably generated by NetBeans.
The build file appears to be pre-compiling your JSPs. (potentially an unnecessary step, as it can compile on the fly, but ok)
You said you changed from using Glassfish to Tomcat.
Have you updated the build file appropriately? What does the build-impl.xml file look like?
Yes it was. Though more correctly the EL interpreter library internal to JSTL was pre EL understood by the container
The change in servlet 2.4/JSP2.0 was that EL expressions became runtime expressions.
So now everything uses the RT version of the code.
Prior to this there were two parallel libraries for JSTL
EL - Tags attributes were defined as taking "String". These string expressions were evaluated as EL within JSTL
RT - Tags attributes were defined as taking runtime expressions for those who wanted to use <%= expr %> with their JSTL tags.
As of JSP2.0 EL expressions were understood by the container - in effect they BECAME runtime expressions.
Because this changed the Tag definitions significantly, the introduced the new URI for the tag library - which was effectively the old RT version rebranded.
So the org.apache.taglibs.standard.tag.rt.core package in the generated code is perfectly legitimate.
ALL the tags are now evaluated as runtime expressions.
It's just that we don't often look at the servlet code generated for a JSP.