what is the values for these Parameters? . I doubt either of any one may return null.
Note: Putting
Java Code in a Jsp is Poor Practice. Use Java classes for Java Code and access the classes from your backend/servlet and forward the return values to JSP for display