Pacific-Design.com

    
Home Index

1. SQL

2. Date

SQL / Date /

SQL Date Range

SELECT * FROM statistics
WHERE DATE_SUB( CURDATE() , INTERVAL 10 DAY ) < dt
ORDER BY  statistics.dt ASC 

SELECT name, datediff(now(),dob)/365 FROM person

SELECT name, round(datediff(now(),dob)/365) FROM person