Welcome to JiKe DevOps Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
234 views
in Technique[技术] by (71.8m points)

mysql - How can I change the time in a $query

I know nothing of coding and have a site where if a reservation is more than 6 minutes old it is deleted. I have looked through the files and found this.

$query = "DELETE 
          FROM $table_app 
          WHERE status = 'reservation' AND created < (NOW() - INTERVAL 6 MINUTE)";

If I change the interval time in this line will it work or is the time taken from somewhere else. If this is the time can I change the units to HOURS OR DAYS. I need to stop the reservation being automatically deleted for at least 6 months.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

Please log in or register to answer this question.

1 Answer

0 votes
by (71.8m points)
等待大神答复

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to JiKe DevOps Community for programmer and developer-Open, Learning and Share
...