Vay
Vay

Reputation: 117

Add days to a mysql datetime row

How can I add 14 days to that: DATE_ADD(p.since, INTERVAL 1 YEAR) ?

I want to check if the row p.since is exactly 1 year and 14 days old in MySQL.

Upvotes: 1

Views: 1136

Answers (1)

zerkms
zerkms

Reputation: 254886

Just nest it to another DATE_ADD:

DATE_ADD(DATE_ADD(p.since, INTERVAL 1 YEAR), INTERVAL 14 DAY)

Upvotes: 3

Related Questions