Nigel, Again, thanks - that is the "rule of thumb" I was looking for!
Mark On Wednesday 14 December 2005 09:57 am, nigel wood wrote: > Mark Phillips wrote: > >2. Generally, what is the most "efficient" way to do this? Is is better to > >issue more queries that gather the "calculated data" or better to issue > > one query for the raw data and then do the calculations in Java? I am > > sure there are many factors that effect the answer to this question - > > server resources, code design, etc. However, I am interested in a best > > practices type of answer or general rule of thumb from the sage experts > > on the list. > > Sorry only just spotted the second half. > > Processing in MySQL will be faster than pulling the dataset back and > processing it. This is particularly true if the database server is > remote from the servlet container. The chief reason is that processing > it on the client add the time needed to copy the raw data over the > network. In Java or C.* data processing performance can be on a par > with MySQL once the data is obtained, against an interpreted language > such as PHP or Perl the database's performance will always win hands > down even if temporary tables are needed. > > If the rocket data doesn't change rapidly the MySQL query cache will > also improve preformance. This feature speeds things by remembering the > answer to your query and replying with a cached version until the > rockets table is next updated. > > Nigel -- Mark Phillips [EMAIL PROTECTED] 602 524-0376 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]