In MySql, there is available
DATE_ADD() function that helps to subtract days from some date. In this example we presented way how to subtract some days from current date.
NOW() functions example
This example subtracts 30 days from current time.
SELECT DATE_ADD(NOW(), INTERVAL -30 DAY);