Stored procedures will be more efficient then using JDBC and directly
running queries. However, the difference may not be noticed unless a large
and complex query was performed. The reason that stored procedures are more
efficient, is that they are stored in the database as optimized queries.
Therefore, they do not need to go through the SQL optimizer, and often no
longer need to go through the SQL parser.
If using regular SQL however, the query will have to go through the SQL
parser, and the query optimizer before it is run. Thus, taking more time
than stored procedures. As I mentioned earlier, if the query is simple
there will be no noticeable difference.
Joseph Karau
Kingland Systems
[EMAIL PROTECTED]
507-536-3629
-----Original Message-----
From: Robuschi (Delfi) [mailto:[EMAIL PROTECTED]]
Sent: Thursday, October 12, 2000 7:35 AM
To: [EMAIL PROTECTED]
Subject: Re: Stored Procedures
I'm just tryin the best solution between simple queries and Stored
Procedures.
So i placed 5 tables, integrally referenced each other, and the main table
has 100.000 records.
I tried a query that joins these tables and a stored procedure that does the
same thing.
The result was the same: 4 seconds to execute both the query and the stored
procedure. So we decided to use queries... there are less troubles in
deploying the application.
Hope this can help you...
Robuschi Roberto -------------------- Delfi srl
P.za Ravenet 1/b - 43100 PARMA
Tel. 0521/932411 Fax 0521/989045
[EMAIL PROTECTED] --- http://www.delfi.it
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets