Reputation: 401
I have the following php script that I need to schedule to run in phpmyadmin. I am using a cron to run it but its not updating the table. It is not giving me an error either so I am sure something is wrong with my php file. Here is the code.
<?php
mysql_connect("xxxx", "xxxx", "xxxx") or die(mysql_error());
mysql_select_db("xxxx") or die(mysql_error());
$query = "update events
INNER JOIN tblfeatureddj
ON events.id_user = tblfeatureddj.id_user
set trending ='2'";
?>
Upvotes: 1
Views: 11061
Reputation: 12442
You can indeed schedule events from within phpMyAdmin (provided you have the proper permissions, of course). From within your database, click the Events tab. From there, you can add a new event (and turn on the "Event scheduler status" button, if the scheduler is turned off). Something like this should do nicely for you:
Upvotes: 6