I have an agent i defined a job for that php agent file .but if second agent run after 1 minutes and previous agent work not finished yet .its make a problem ..... i want to flag selected rows in every agent that if another agent runs new query they haven't interference
how i change this query is the best way is make a field in that table for selected or not ?and update that field ?
db::query("SELECT 1000 FROM web-service WHERE `state`= 1 AND `fetch_id`="fetchid" ")//
1-state = 1 is condition for my products
2-i use fetch id to imputation id to each agent what is the best way ?