yeah, it's a pity cf doesn't have a built in 'cachedsince' value on returned queres. CF7 has gotten part of the way there with the new queryname.Cached value returning true/false but just need that last little bit..
jb. On 5/11/05, Scott Mulholland <[EMAIL PROTECTED]> wrote: > Yeah, for simplicities sake I'll go with the other one, heh. > > Thanks for the help guys. > > -----Original Message----- > From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] > Sent: Tuesday, May 10, 2005 7:19 PM > To: CF-Talk > Subject: RE: Cached query - Any way to tell when it was cached? > > > I think Ian's may be the way to go. I am using > > cachedwithin as the data > > changes frequently so we cache it for 6 hours. I don't > > think cachedafter > > will work. > > sure it will -- although the alternative is simpler... > but fyi here's the way to accomplish 6 hr caching with cachedafter: > > <cfparam name="application.queryname.cachedafter" type="date" > default="#now()#"> > > <cfif abs(datediff("h",application.queryname.cachedafter,now())) gte > 6> > <cfset application.queryname.cachedafter = now()> > </cfif> > > <cfquery name="queryname" > cachedafter="#application.queryname.cachedafter#"> > .......</cfquery> > > <cfoutput>report last generated on > #application.queryname.cachedafter#</cfoutput> > > s. isaac dealey 954.522.6080 > new epoch : isn't it time for a change? > > add features without fixtures with > the onTap open source framework > > http://www.fusiontap.com > http://www.sys-con.com/author/?id=4806 > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:206318 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

