-Karl- Posted June 6, 2010 Share Posted June 6, 2010 This is confusing the hell out of me. I have my code, with a working query: <?php include ('config.php'); include ('functions.php'); $sql = mysql_query("SELECT * FROM " . $table ." WHERE `min` = '' ORDER BY `itemid` ASC"); while ($arr = mysql_fetch_assoc($sql)) { massupdateData($arr['name']); } ?> If you need to see the massupdateData function just ask. Anyway, when running the query in PHPMyAdmin it works fine and displays the fields where min = '', however, when I run the PHP file. It updates items which I know definitely have some value in the min field. I don't want to post my function here, however, if you can help me I will PM you it Thanks ~Karl Quote Link to comment https://forums.phpfreaks.com/topic/204005-updating-fields-where-field/ Share on other sites More sharing options...
Mchl Posted June 6, 2010 Share Posted June 6, 2010 You know you can usr this WHERE condition in your UPDATE query, right? Anyway, there doesn't seem to be anything wrong with the query, so it must be within the functinon. Quote Link to comment https://forums.phpfreaks.com/topic/204005-updating-fields-where-field/#findComment-1068502 Share on other sites More sharing options...
-Karl- Posted June 6, 2010 Author Share Posted June 6, 2010 May I PM you my function? Quote Link to comment https://forums.phpfreaks.com/topic/204005-updating-fields-where-field/#findComment-1068503 Share on other sites More sharing options...
Mchl Posted June 6, 2010 Share Posted June 6, 2010 No Quote Link to comment https://forums.phpfreaks.com/topic/204005-updating-fields-where-field/#findComment-1068515 Share on other sites More sharing options...
ignace Posted June 6, 2010 Share Posted June 6, 2010 No Post it so everyone can help you, remove credential details if any. Quote Link to comment https://forums.phpfreaks.com/topic/204005-updating-fields-where-field/#findComment-1068536 Share on other sites More sharing options...
-Karl- Posted June 6, 2010 Author Share Posted June 6, 2010 I'll pass. Quote Link to comment https://forums.phpfreaks.com/topic/204005-updating-fields-where-field/#findComment-1068588 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.