473,545 Members | 529 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Page Caching, MVCC, Postgresql

I had a problem today where I had an editor page (edit2.php) that
posted data to PostgreSQL, and then a view page (view.php) that read
it in and displayed it. At first I thought this was an MVCC issue in
PostgreSQL because it was not displaying the latest changes, but the
second-to-latest changes. The end user was using IE 5, so he saw the
problem, but I was using Mozilla in RH9 Linux, so I never saw the
problem. Turns out it had nothing to do with MVCC feature in
PostgreSQL.

I resolved the problem by adding this in my banner.php that loads with
a require() at the top of my HTML in order to display a banner on each
page.

if ($nocache_page) {
header("Expires : Mon, 26 Jul 1997 05:00:00 GMT"); // Date in the
past
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
}

and on pages where I needed to ensure no cache was used, I implemented
this feature by simply putting

$nocache_page = TRUE;

in it before banner.php was called.

By using the condition check, it permits me to have some pages to
cache and other pages to not.
Jul 17 '05 #1
0 1447

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
4213
by: Steven D.Arnold | last post by:
How good is Postgres' performance for massive simultaneous insertions into the same heavily-indexed table? Are there any studies or benchmarks I can look at for that? I understand Postgres uses MVCC rather than conventional locking, which makes it easier to do parallel inserts. In my environment, I will have so many inserts that it is...
0
1727
by: Troy Simpson | last post by:
Hi, I have a website which is made up of dynamic pages. Each page that's loaded has some code which looks at which template to load amongst other things, which causes the page to take a little while to be processed. At the moment I have programmatic page caching in the "loader" using paramater caching to send a cached version of every...
3
1627
by: Janaka | last post by:
Hi All, I'm having a problem with Page Output caching on a page that contains a DataGrid. Basically the page pulls up some data for sales information from the DB. Some of this has to be calculated on the fly when the request is made, and so I thought it would be ideal to cache the page for a set amount of time. I've placed the following...
7
1505
by: moondaddy | last post by:
I have a products catalogue that I'm putting online and there will be between 20 to 50 different pages of products. Each page contains a datagrid of products for a given category. However, the categories change from time to time so the list of categories must be dynamic and database driven (as is the menu used to select the category to load...
3
2470
by: DC | last post by:
Hi, (ASP.Net 1.1) is it possible to (programmatically and globally) deactivate page fragment caching? We have only two scenarios, development stage where we want caching off and testing where we want caching on. Is this doable? I think there is a config switch in 2.0, anything in 1.1? TIA for any hint,
6
1901
by: Jim Steinberger | last post by:
Hey all - my inaugural post, I have a Java web application on Tomcat 5 using pg73jdbc3.jar to connect to PostgreSQL 7.3.4 running on the same server (Red Hat Linux ). I have a Perl script that drops the database and rebuilds it with all of our
2
3106
by: Martin Sarsale | last post by:
Dear All: Im looking for solutions (Free Software is better) to do query result caching. Thanks to the people from #postgresql I know that postgres doesn't do that by himself and the solution should be some kind of middle ware. This is our problem: we are executing the same set of SELECT SP/queries hundreds of times, without updating the...
5
6069
by: nd02tsk | last post by:
Hello Harrison Fisk from MySQL claims in this thread: http://forums.mysql.com/read.php?35,3981,4245#msg-4245 That there are no major differences between InnoDB and MVCC concurrency. Is this true?
20
6082
by: Troels Arvin | last post by:
Hello, In a rather large database, I face this problem: Several tables are regularly updated through rather long-running DELETE +INSERTs. Using uncommitted read as isolation level seems unsafe, as I'd like consistent data (that's one of the main points of using a DBMS in the first place, in my opinion). Almost all other significant...
0
7465
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7656
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
1
7416
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7752
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
1
5325
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
4944
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3441
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1878
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
0
701
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.