While you can technically do anything you want in a
JSP, it is considered bad form to have the view (in this case your jsp) making direct access to the database. The typical way you would handle this in
Struts is to have your action place some kind of value object into some scope which your jsp would then access.
In other words... Your Action populates a bean (the value object) based on data contained in some business object, and places that bean into some scope. It is this business object that actually communicates with the database. The JSP then references your bean and displays its data appropriately.
If you insist on your jsp directly communicating with your database, perhaps the
JSP forum would be more appropriate.