tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Derek Mahar" <>
Subject RE: sql tag
Date Thu, 20 May 2004 22:02:24 GMT
I'd use <sql:query> in the JSP page, but Model-View-Controller (MVC)
purists strongly discourage using the sql tags at all because they more
tightly couple the View (JSP page) with the Model (database) which
violates the MVC principle of Model-View separation.  An MVC designer
prefers that a JSP page indirectly access a datasource through
Enterprise Java Beans (EJBs) or some other object-relational mapping
system.  In a basic JSP and EJB model, a JSP page refers to an EJB on an
EJB server through a Java Bean or Expression Language (EL) object and
the EJB server maps the EJB to a row in a database table.  When the JSP
page changes the EL object, it changes the EJB, which in turn updates
the row in the table.


-----Original Message-----
From: Karl Coleman [] 
Sent: May 11, 2004 4:53 PM
To: Tag Libraries Users List
Subject: sql tag

What is the general consensus on the sql tag? I want to fill a drop down
with values from a table in a database. Is it better to use the sql tag
in the jsp or do it in the servlet the jsp is called from? Or is in 6 of
one, half-dozen of the other?


To unsubscribe, e-mail:
For additional commands, e-mail:

NOTICE: This email contains privileged and confidential information and is intended only for
the individual to whom it is addressed. If you are not the named addressee, you should not
disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail
if you have received this transmission by mistake and delete this communication from your
system. E-mail transmission cannot be guaranteed to be secured or error-free as information
could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses.

AVIS: Le présent courriel contient des renseignements de nature privilégiée et confidentielle
et n’est destiné qu'à la personne à qui il est adressé. Si vous n’êtes pas le destinataire
prévu, vous êtes par les présentes avisés que toute diffusion, distribution ou reproduction
de cette communication est strictement interdite.  Si vous avez reçu ce courriel par erreur,
veuillez en aviser immédiatement l’expéditeur et le supprimer de votre système. Notez que
la transmission de courriel ne peut en aucun cas être considéré comme inviolable ou exempt
d’erreur puisque les informations qu’il contient pourraient être interceptés, corrompues,
perdues, détruites, arrivées en retard ou incomplètes ou contenir un virus.  

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message