Solved

Result set doesn't refresh

Posted on 2000-03-23
3
182 Views
Last Modified: 2013-12-24
My application does some simple queries (cfupdates, cfinserts), but sometimes the results displayed don't accurately reflect the contents of the database.  My browser is set to reload the page on every visit and the database does have the correct data in it during these queries.  Does CF cache resultsets or use cached pages even though disabled in the browser (IE)?  Any other ideas?  Please help.  Thanks.
0
Comment
Question by:peteodonnell
  • 2
3 Comments
 
LVL 6

Expert Comment

by:acampoma
Comment Utility
I had the same problem. and I found this solution on a site called www.cfnewbie.com
let me know if it works!!
Alex


Insert these line at the top of your templates.
<meta http-equiv="pragma" content="nocache">
<meta http-equiv="expires" content="1 January 1900 00:00:00 PST">

I actually put them in my application.cfm
0
 
LVL 2

Author Comment

by:peteodonnell
Comment Utility
The problem was actually that a query was being executed in the application.cfm and later javascript was attempting to load multiple frames also executing queries.  
Somehow I think CF was caching old resultsets because of this.  
This leads me to another question.  Is the application.cfm prepended to all templates loaded?  Do you know of any good documentation on the application.cfm and how it is actually processed?
0
 
LVL 6

Accepted Solution

by:
acampoma earned 20 total points
Comment Utility
The application.cfm is prepended to all cold fusion templates in any subfolder.
if you have an application.cfm in your main directory, all templates will use this application.cfm unless there is another application.cfm in a subdirectory. Any templates in that subdirectory or lower will use the second application.cfm file.
I have found some documentation on the topic in mastering cold fusion 4.
But mainly I just usee the application.cfm for for global variables such as database name, background, etc.
hope this helps
Alex
 
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Join & Write a Comment

Most ColdFusion developers get confused between the CFSet, Duplicate, and Structcopy methods of copying a Structure, especially which one to use when. This Article will explain the differences in the approaches with examples; therefore, after readin…
If you don't have the right permissions set for your WordPress location in IIS, you won't be able to perform automatic updates. Here's how to fix the problem.
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now