Quantcast
Channel: dBforums – Everything on Databases, Design, Developers and Administrators
Viewing all articles
Browse latest Browse all 13329

Date Difference from same column

$
0
0
Dear all, I've a table like below. Could anyone tell me what will be the query to get the date difference of last two payment dates of distinct user ID.

user_id amount_paid payment_date
X 102 11/2/13
A 89 18/2/13
X 93 15/2/13
X 85 17/1/12
Z 87 19/2/13
A 86 3/1/13
A 78 13/1/13

Viewing all articles
Browse latest Browse all 13329

Trending Articles