PDA

View Full Version : how to set autometic sql table update in a spacific time


bijaybd
11-22-2009, 09:43 PM
in sql how to set update the sql query in a spacific time in a day for example : it will upload once in a day.Is there any function like this in sql like cron job i search but didnt found it actually so anybody knows where i will find it ???



UPDATE `chat_users` SET `abc` = `abc` * 1.02 WHERE `abc` > 20;
UPDATE `chat_users` SET `tposts` = 0 WHERE `tposts` > 0;

seco
11-22-2009, 10:21 PM
you need to run a script via cron, thats about it.

guelphdad
11-22-2009, 10:23 PM
MySQL 5.1 includes an event scheduler.
http://dev.mysql.com/doc/refman/5.1/en/events.html

bijaybd
11-23-2009, 03:21 PM
script via cron oh... i guess its good but the thing is it will work ????

bijaybd
11-23-2009, 03:46 PM
hey thanks to both of you but sql one is good i guess the event system i have done it and it works lets see after 24 hours thanks to both of you

bijaybd
01-22-2010, 10:58 PM
i have used it via cron but its not working why i dont know it was fine i saw everything like the tutorial but not working