Home > Database > Mysql Tutorial > mysql生日提醒_MySQL

mysql生日提醒_MySQL

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-01 13:28:57
Original
1424 people have browsed it

bitsCN.com

mysql生日提醒

 

Java代码  SELECT   datediff(DATE_ADD("1989-01-02",INTERVAL TIMESTAMPDIFF(YEAR,"1989-01-02","2013-10-15") YEAR),NOW())   
Copy after login

 

 

先计算出生日离当前日期的年份差,

 

在用生日+上年份差与当前时间做减法
 

bitsCN.com
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Issues
MySQL stops process
From 1970-01-01 08:00:00
0
0
0
Error when installing mysql on linux
From 1970-01-01 08:00:00
0
0
0
Mysql cannot start
From 1970-01-01 08:00:00
0
0
0
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template