...

View Full Version : Updating specific values in a column



Mike Miller
07-10-2011, 09:55 PM
Hi guys,

I have a content management system that allows me to add/edit/delete entries in our site's database. I'm trying to update a column in a table that has different values. One of the values is "Unknown." and I'm trying to replace all instances with "Not available." Here's the code:
Code:


UPDATE axes
SET req = "Not available."
WHERE req = "Unknown.";


Simple, right? It does work - the changes show up when I view the entries in the DB; however, when I go visit one of the entries to see if the changes were made, I still see "Unknown." in the req field. In other words, the site does not display the change.

Any idea why this is happening? I do not want to manually go through each entry with the unknown value, as there are over 1000 such entries.

Thanks much!

conware
07-11-2011, 01:24 PM
If you see the changes made in your database but your website is still displaying the old text. Make sure that you have cleared your cache.
Maney CMS sites cache there queries to speed up the page loading.

Mike Miller
07-11-2011, 07:19 PM
If you see the changes made in your database but your website is still displaying the old text. Make sure that you have cleared your cache.
Maney CMS sites cache there queries to speed up the page loading.
Are you referring to my browser cache? If so, I have cleared that quite a few times. No go.

I even reset the query cache and that didn't do the trick either. Running MySQL 5.1.

Old Pedant
07-11-2011, 08:55 PM
Possibly the code (PHP?) that retrieves the req value from the DB is interpreting the value. If it is anything other than some particular set of values, perhaps it displays "Not available."

travin69
08-16-2011, 12:56 PM
Did clearing your cache work? I am having a similar issue with a wordpress plugin I am working on.

jbh5000
08-18-2011, 08:26 AM
When I had a similar problem I did a hard refresh (CTRL+F5) and that worked for me.

AutoGlassIdol
08-23-2011, 12:48 AM
clearing dns cache and computer cache would do the trick sometimes?

Kevin Richards
08-29-2011, 12:14 PM
I've also solved this problem using a hard refresh (CTRL = F5). Hopefully it's that simple of a fix

travin69
08-29-2011, 04:35 PM
Thanks Kevin. Good looking out. Still wondering if clearing the cache worked.

jbh5000
08-31-2011, 07:25 AM
If you try the hard reset and clear the cache and it still doesnt work then try this from the command prompt:

ipconfig /flushdns

dhape
09-17-2011, 11:37 PM
What DBMS are you using?

horatio
10-17-2011, 01:44 PM
If you try the hard reset and clear the cache and it
still doesnt work then try this from the command prompt:

ipconfig /flushdns

Thanks, I tried everything to solve this problem, well almost everything but this did the trick. I haven't been here long but this is a great forum!



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum