select users as per their years completion date current year

From: Arup Rakshit <aruprakshit(at)rocketmail(dot)com>
To: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: select users as per their years completion date current year
Date: 2014-06-30 13:05:53
Message-ID: 1404133553.69103.YahooMailNeo@web193906.mail.sg3.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Suppose I have users table. I have a joining_date. Now I only want those users who completed 5 years, 10 years, and in which date they completed. 

Example:

Out of all users, suppose below users only -

Foo_1 on 24/1/2014 completed 10 years
Foo_2 on 2/2/2014 completed  10 years
Foo_3 on 14/3/2014 completed 15 years
Foo_4 on 21/3/2014 completed 5 years

They should come in the output 
 
Regards,
Arup Rakshit

Browse pgsql-general by date

  From Date Subject
Next Message Emre Hasegeli 2014-06-30 13:46:42 Re: Examples of projects that use Postgres "as API server"
Previous Message Francisco Olarte 2014-06-30 12:05:15 Re: Very high latency, low bandwidth replication