MySQL Forums
Forum List  »  PHP

MYSQL appears to not recache Selected table after Insert
Posted by: Michael Walker
Date: September 07, 2011 07:43AM

Hello, I have a php page that works OK until I add a new item to a table. Thats new item is there but won't appear in sebsequent Selects unless I close IE and reopen.
I know MYSQL caches select statements and is supposed to update a cache if the underlying table changes. But it isn't. Any ideas?
Full explanation below.

DB has two (relevant) tables. Manfuacturer and Type.
User selects Manufacturer from dropdown list and filtered Types appear in Type list. Type is populated through AJAX and works well.
Sometimes I need to add a new Type. This uses a similar page to the search page (button on search page Add New Record opens new page). AJAx writes the new type item to the Type table and then selects it out again to populate the Type field with the entry seleted. Again that all works.
On going back to the search page and selecting the same manufacturer, the new item isn't listed.
Close IE, reopen, relogon and open search page, click on manufacturer and new entry appears.
Obviously, I can't make the users close IE every time they create a new type (although that is rare).
Screen capture sequence is available if you want it.

Options: ReplyQuote

Written By
MYSQL appears to not recache Selected table after Insert
September 07, 2011 07:43AM

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.