wellscam Posted October 9, 2008 Share Posted October 9, 2008 I have a SQL Querry that I need to run every 30min. I'm hoping there is a way to have it automatically run on a web page then IF there are results, send me an email. The query was written in Access, so I need to convert it to PHP and see if there is a way to have some sort of scheduled task or something run the page every 30min. Does anyone know how to do this? Here is the query: SELECT AllInfo.IO, AllInfo.CO, AllInfo.DateTime, AllInfo.Extension, AllInfo.Duration, AllInfo.AC, AllInfo.PhN FROM AllInfo WHERE (((AllInfo.IO)="Out") AND ((AllInfo.DateTime)>DateAdd("n",-30,Now())) AND ((CInt([AllInfo].[CO])) Between 1 And 23) AND ((AllInfo.LD)="Y")); Link to comment https://forums.phpfreaks.com/topic/127728-scheduled-tasks/ Share on other sites More sharing options...
refiking Posted October 9, 2008 Share Posted October 9, 2008 Check with your hosting provider. They should have a cron job feature on your control panel. You can usually run it every 15 min, 30 min, hour, week, month, etc. Link to comment https://forums.phpfreaks.com/topic/127728-scheduled-tasks/#findComment-661046 Share on other sites More sharing options...
wellscam Posted October 9, 2008 Author Share Posted October 9, 2008 This is actually hosted locally on one of my server, I'm just very new to all of this. It's on a Windows Server 2003 running IIS 6.0. Link to comment https://forums.phpfreaks.com/topic/127728-scheduled-tasks/#findComment-661187 Share on other sites More sharing options...
wellscam Posted October 9, 2008 Author Share Posted October 9, 2008 So I can create a scheduled task on the server to run the script, but how do I write that kind of page that will do what I want it to? Anyone? Link to comment https://forums.phpfreaks.com/topic/127728-scheduled-tasks/#findComment-661361 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.