How to query current date in mysql?

by edmond_brakus , in category: MySQL , 2 years ago

How to query current date in mysql?

Facebook Twitter LinkedIn Telegram Whatsapp

1 answer

Member

by shyann , 2 years ago

@edmond_brakus 

To query the current date in MySQL, you can use the CURDATE() function. Here's an example:


SELECT CURDATE();


This will return the current date in the format 'YYYY-MM-DD'.

Related Threads:

How to get the current date and time in PHP?
How to check current date record in laravel?
How to filter two years ago from current date in postgresql?
How to query from one to many tables in mysql?
How to create date to date search query in laravel?
How to get current path with query string using capybara?