Jump to content
MakeWebGames

Gang Age


lucky3809

Recommended Posts

Hello,

I've looked all around on here for gang age but cant find anything about it... And I think my cron is wrong because it's not updating the database...

I have the following for gang age...

$db->query("UPDATE gangs SET daysold=daysold+1, boxes_opened=0");

 

Would that be right?

or would it be something like this...

 

$db->query("UPDATE gangs SET daysold=daysold+1 WHERE gangID > 0");

 

??

Link to comment
Share on other sites

None are them are right. Why?

Because your SET is wrong & WHERE(Second query). Your setting `daysold` wrong. What will that be setting? Users or Gang? And your where doesn't need to be `gangID`. I think something might come up if it's an invalid gang ID, so you might want to change that. :)

I think it should be something like this:

$db->query("UPDATE `users` SET `daysingang` = `daysingang` + 1 WHERE `gang` > 0"); // Should work 

 

Reply back if this helps. ;)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...