<html><body><div style="color:#000; background-color:#fff; font-family:times new roman, new york, times, serif;font-size:10pt">Thanks Tatsuo!<br><br>I have setup a Master and Slave configuration and set relcache_expire as 600 in pgpool.conf. Now I do manual testing within 600 seconds. <br>I connect to database through pgpool port 9999. At the psql prompt, I created a table with 3 columns:<br><br>CREATE TABLE phonebook(phone VARCHAR(32), name VARCHAR(32), address VARCHAR(64));<br><br>I inserted proper values and then executed the select query which returns proper values.<br>SELECT * FROM phonebook ORDER BY name;<br><br>Now, I alter the table and rename the column 'name' with 'firstname'<br>ALTER TABLE phonebook RENAME COLUMN name TO firstname;<br><br>Now, the same select query returns me the ERROR "column "name" does not exist".  I thought it should return fine because relation cache would not have updated table structure, right? Or am I missing
 something?<br><br><br><div style="font-family: times new roman, new york, times, serif; font-size: 10pt;"> <div style="font-family: times new roman, new york, times, serif; font-size: 12pt;"> <div dir="ltr"> <font size="2" face="Arial"> <hr size="1">  <b><span style="font-weight:bold;">From:</span></b> Tatsuo Ishii <ishii@postgresql.org><br> <b><span style="font-weight: bold;">To:</span></b> sandeeptt@yahoo.com <br><b><span style="font-weight: bold;">Cc:</span></b> pgpool-general@pgpool.net <br> <b><span style="font-weight: bold;">Sent:</span></b> Tuesday, February 14, 2012 2:52 PM<br> <b><span style="font-weight: bold;">Subject:</span></b> Re: [pgpool-general: 221] Re: More information on relcache_expire<br> </font> </div> <br>
> right, that makes sense. Thanks!<br>> <br>> BTW, how do we know that the query result is returned from the cache or not?<br><br>Please look into PostgreSQL log. If you see access to pg_class or so<br>before user's query, that is the accessed from pgpool, thus cache is<br>not used.<br>--<br>Tatsuo Ishii<br>SRA OSS, Inc. Japan<br>English: http://www.sraoss.co.jp/index_en.php<br>Japanese: http://www.sraoss.co.jp<br><br>> ________________________________<br>>  From: Tatsuo Ishii <<a ymailto="mailto:ishii@postgresql.org" href="mailto:ishii@postgresql.org">ishii@postgresql.org</a>><br>> To: <a ymailto="mailto:sandeeptt@yahoo.com" href="mailto:sandeeptt@yahoo.com">sandeeptt@yahoo.com</a> <br>> Cc: <a ymailto="mailto:pgpool-general@pgpool.net" href="mailto:pgpool-general@pgpool.net">pgpool-general@pgpool.net</a> <br>> Sent: Tuesday, February 14, 2012 2:11 PM<br>> Subject: Re: [pgpool-general: 221] Re: More information on
 relcache_expire<br>>  <br>>> I mean, let's say I define the value of relcache_expire as "600" seconds. and the TABLE in cache is ALTERED before that. That means my query will produce the wrong result because the relation cache is not yet updated/expired, right?<br>> <br>> Yes.<br>> <br>> On what basis one would define the value of relcache_expire in pgpool.conf?<br>> <br>> I don't think changing table structure so frequently is a real life<br>> usecase. Rather I think it happens during application development:<br>> table structures are not stable.<br>> <br>> If your customer really wants to change table structure every 5<br>> minutes, probably there's something wrong with user's work flow<br>> anyway.<br>> --<br>> Tatsuo Ishii<br>> SRA OSS, Inc. Japan<br>> English: <a href="http://www.sraoss.co.jp/index_en.php" target="_blank">http://www.sraoss.co.jp/index_en.php</a><br>> Japanese: <a
 href="http://www.sraoss.co.jp" target="_blank">http://www.sraoss.co.jp</a><br>> <br>>> ________________________________<br>>>  From: Sandeep Thakkar <<a ymailto="mailto:sandeeptt@yahoo.com" href="mailto:sandeeptt@yahoo.com">sandeeptt@yahoo.com</a>><br>>> To: "<a ymailto="mailto:pgpool-general@pgpool.net" href="mailto:pgpool-general@pgpool.net">pgpool-general@pgpool.net</a>" <<a ymailto="mailto:pgpool-general@pgpool.net" href="mailto:pgpool-general@pgpool.net">pgpool-general@pgpool.net</a>> <br>>> Sent: Monday, February 13, 2012 1:58 PM<br>>> Subject: [pgpool-general: 220] More information on relcache_expire<br>>>  <br>>> <br>>> - Add relcache_expire directive to control the expiration of the internal system catalog cache. ALTER TABLE might make these cache values obsoleted and the new directive will make the risk lower(Tatsuo)<br>>>  I would like to know how to make use
 of this directive? A test case will help.<br>>> <br>>> Thanks.<br>>> <br>>> <br>>> _______________________________________________<br>>> pgpool-general mailing list<br>>> <a ymailto="mailto:pgpool-general@pgpool.net" href="mailto:pgpool-general@pgpool.net">pgpool-general@pgpool.net</a><br>>> http://www.pgpool.net/mailman/listinfo/pgpool-general<br><br><br> </div> </div>  </div></body></html>