title: Automatically delete data using date MySQL trigger
body: <p>I need  to use trigger for one of my database, this is my offer data table</p>
  
  <pre><code>CREATE TABLE IF NOT EXISTS `offer_detail` (
    `id` int(60) NOT NULL AUTO_INCREMENT,
    `company_id` int(60) NOT NULL,
    `offertype_id` int(60) NOT NULL,
    `category_id` int(60) NOT NULL,
    `place_id` int(100) NOT NULL,
    `offer_title` varchar(150) NOT NULL,
    `offer_description` text NOT NULL,
    `image` varchar(150) NOT NULL,
    `coupon_id` varchar(60) NOT NULL,
    `price` text NOT NULL,
    `unit_id` varchar(60) NOT NULL,
    `price_now` varchar(60) NOT NULL,
    `offer_from` varchar(80) NOT NULL,
    `offer_to` varchar(80) NOT NULL,
    `user_id` int(10) NOT NULL,
    `created` varchar(11) NOT NULL,
    `modified` varchar(10) NOT NULL,
    `Active` varchar(100) NOT NULL,
    PRIMARY KEY (`id`)
  );
  </code></pre>
  
  <p>I get offer duration using <strong>offer_from</strong> to <strong>offer_to</strong></p>
  
  <p>I need to delete offer detail from datatable if offer_to is earlier than current time, like this :</p>
  
  <pre><code>DELETE FROM Offer_detail
  WHERE offer_to&lt; NOW()
  </code></pre>
  
  <p>I need do this automatically, how to do this?</p>