Brown Limie
Brown Limie

Reputation: 2599

mysql triggers date

I want to have a select statement inside the mysql trigger that has the following:

SELECT id WHERE date = TODAY'S TAKE in Y-m-d format

How do I get today's date in Y-m-d format in the select statement above?

thanks!

Upvotes: 0

Views: 138

Answers (1)

Edoardo Pirovano
Edoardo Pirovano

Reputation: 8334

Use the CURDATE() function.

 SELECT id WHERE date = CURDATE();

Upvotes: 1

Related Questions