you could check and see if the query exists before rerunning it.


<cfif not isdefined("phonelist")>
<cfquery name="phonelist" datasource="myDSN" cachedwithin="CreateTimeSpan(0,
3, 0, 0)">
select * 
from phonelist
</cfquery>
</cfif>





> -----Original Message-----
> From: Mike Connolly [SMTP:[EMAIL PROTECTED]]
> Sent: Friday, November 10, 2000 8:02 AM
> To:   CF-Talk
> Subject:      RE: Best Practices
> 
> On point two, I wouldn't put queries in the application.cfm unless you
> want
> it to execute everytime to access ANY cf template.
> 
> Also, if this is the case, does the content of the query change frequently
> throughout the application?
> If not, it would be best to cache the query to avoid unecessary execution
> at
> every page.
> 
> 
> 
> > -----Original Message-----
> > From:       David Clay [SMTP:[EMAIL PROTECTED]]
> > Sent:       10 November 2000 13:49
> > To: CF-Talk
> > Subject:    Best Practices
> > 
> > This is a MIME message. If you are reading this text, you may want to 
> > consider changing to a mail reader or gateway that understands how to 
> > properly handle MIME multipart messages.
> > 
> > --=_702B4CD5.E687E0B3
> > Content-Type: text/plain; charset=US-ASCII
> > Content-Transfer-Encoding: quoted-printable
> > Content-Disposition: inline
> > 
> > I am looking for the bast practices on the following questions:
> > 
> > 1) Is it best to have 1 large database with many tables or vise versa.
> > 
> > 2) Is it best to set  queries in the application.cfm or in the page it =
> > self, knowing this is a reoccurring query.
> > 
> > Thank you for your time.
> > 
> > Dave Clay
> > Internet Facilitator
> > Trus Joist, A Weyerhaeuser Business
> > 5995 Greenwood Plaza Blvd, Suite 100
> > Greenwood Village, CO 80111
> > 303.770.8506
> > 
> > 
> > --=_702B4CD5.E687E0B3
> > Content-Type: text/plain
> > Content-Disposition: attachment; filename="David Clay.vcf"
> > 
> > BEGIN:VCARD
> > VERSION:2.1
> > X-GWTYPE:USER
> > FN:Clay, David
> > EMAIL;WORK;PREF;NGW:[EMAIL PROTECTED]
> > TEL;PREF;FAX:(303) 770-8506
> > X-GWUSERID:clayd
> > ADR;DOM;WORK;PARCEL;POSTAL:;Denver
> > LABEL;DOM;WORK;PARCEL;POSTAL;ENCODING=QUOTED-PRINTABLE:Clay, David=0A=
> > Denver
> > ORG:;Engineering Automation Group
> > N:Clay;David
> > TEL;WORK:(303) 967-1558
> > TITLE:Web Facilitator
> > END:VCARD
> > 
> > 
> > --=_702B4CD5.E687E0B3--
> >
> --------------------------------------------------------------------------
> > ----------------------
> > Archives: http://www.mail-archive.com/[email protected]/
> > Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists or
> send
> > a message with 'unsubscribe' in the body to
> > [EMAIL PROTECTED]
> 
> 
> -----------------------------------------------
> Any opinions expressed in this message are those of the individual and not
> necessarily the company.  This message and any files transmitted with it
> are confidential and solely for the use of the intended recipient.  If you
> are not the intended recipient or the person responsible for delivering to
> the intended recipient, be advised that you have received this message in
> error and that any use is strictly prohibited.
> 
> Sapphire Technologies Ltd
> http://www.sapphire.net
> --------------------------------------------------------------------------
> ----------------------
> Archives: http://www.mail-archive.com/[email protected]/
> Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists or send
> a message with 'unsubscribe' in the body to
> [EMAIL PROTECTED]
------------------------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists or send a message 
with 'unsubscribe' in the body to [EMAIL PROTECTED]

Reply via email to