SELECT * FROM users WHERE created >= CURDATE();
But I think you mean created < today
You can compare datetime with date, for example: SELECT NOW() < CURDATE()
gives 0
, SELECT NOW() = CURDATE()
gives 1
.
More Related Contents:
- MySQL Query GROUP BY day / month / year
- Error in MySQL when setting default value for DATE or DATETIME
- Difference between two dates in MySQL
- MySQL Query to select data from last week?
- How to convert number of week into date?
- Set NOW() as Default Value for datetime datatype?
- Group mysql query by 15 min intervals
- SQL Query to show nearest date?
- How to get current date & time in MySQL?
- how to cast the hexadecimal to varchar(datetime)?
- Get total hours worked in a day mysql
- MySQL: Insert datetime into other datetime field
- Using LIMIT within GROUP BY to get N results per group?
- How to perform grouped ranking in MySQL
- Ordering by specific field value first
- MySQL “Group By” and “Order By”
- How to change the CHARACTER SET (and COLLATION) throughout a database?
- The total number of locks exceeds the lock table size
- How to subtract hours from a datetime in MySQL?
- MySQL “IN” operator performance on (large?) number of values
- MySQL Select last 7 days
- Difference between two table structure
- Difference between SET autocommit=1 and START TRANSACTION in mysql (Have I missed something?)
- How to retrieve JSON data from MySQL?
- MySQL equivalent of Oracle’s SEQUENCE.NEXTVAL
- Why MySQL is giving error “Not allowed to return a result set from a function”?
- When to use a left outer join?
- #1060 – Duplicate column name ‘id’
- In what order are MySQL JOINs evaluated?
- Update multiple rows with multiple ‘where’ clauses for each individual row