Jump to content

Update query not working properly


HCProfessionals

Recommended Posts

$db->query( "UPDATE user_resources, user_buildings, user_units_nonbattle SET user_resources.uGold=user_resources.uGold+(user_buildings.uTownCenterLevel*(user_units_nonbattle.uMiner*10))" );

 

When the cron runs, it updates everyone the same regardless. Any idea what i'm doing wrong?

Link to comment
https://forums.phpfreaks.com/topic/230008-update-query-not-working-properly/
Share on other sites

$db->query( "UPDATE user_resources, user_buildings, user_units_nonbattle SET user_resources.uFood=user_resources.uFood+50+(user_buildings.uTownCenterLevel*(user_units_nonbattle.uHunter*10))" );

 

This one is working properly. This is also the only one that adds +50 every time the cron runs.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.