How to get age in years,months and days using Oracle

前端 未结 4 1783
-上瘾入骨i
-上瘾入骨i 2020-12-17 03:53

I\'m trying to print for each person its age using this format :

E.g : 19 years , 8 months , 13 days.

I\'ve googled a lot and I\'ve noticed that there is a s

4条回答
  •  清酒与你
    2020-12-17 04:19

    Another simplified way for getting months would be-

    TRUNC(MOD(months_between(sysdate,hiredate),12)) AS months
    

提交回复
热议问题