Hi I am currently working on a scheduler for meeting,conference etc. This is my scenario. I have 3 fields in my db(employee, date_from, date_to).
Employee: greedyisgood
Date_from: 2009-02-14
Date_to: 2009-02-15
What I want is when the date_to is already elapse or past, example today is already 2009-02-16. The entire rows with previous dates will be automatically erase in the database. So that the user can create a new schedule again.
Is it possible? Thanks in advance
help with time deletion of row in sql
Moderator: General Moderators
-
greedyisg00d
- Forum Commoner
- Posts: 42
- Joined: Thu Feb 12, 2009 2:48 am
Re: help with time deletion of row in sql
Yes, it's possible 
What have you tried so far?
What have you tried so far?
There are 10 types of people in this world, those who understand binary and those who don't
-
greedyisg00d
- Forum Commoner
- Posts: 42
- Joined: Thu Feb 12, 2009 2:48 am
Re: help with time deletion of row in sql
Sorry I am currently new to php and mysql. Any sample codes there so that I can analyze it. Thanks
Re: help with time deletion of row in sql
Take a look at:
http://dev.mysql.com/doc/refman/5.0/en/delete.html and
http://dev.mysql.com/doc/refman/5.1/en/ ... nction_now
these are what you need to build the proper query.
Try building it and if you still have difficulties doing it, post you queries so we can help you.
http://dev.mysql.com/doc/refman/5.0/en/delete.html and
http://dev.mysql.com/doc/refman/5.1/en/ ... nction_now
these are what you need to build the proper query.
Try building it and if you still have difficulties doing it, post you queries so we can help you.
There are 10 types of people in this world, those who understand binary and those who don't