Quantcast
Channel: Transact-SQL forum
Viewing all articles
Browse latest Browse all 23857

Find date + month after comparing to another date

$
0
0

I have 2 columns:

CutoffDate = '08/03/2013'

CurrentDueDate = '05/02/2012' -- this needs to be updated.

If the CurrentDueDate > CutoffDate then

CurrentDueDate = The same day of the month following the CutoffDate

I want to update using TSQL the CurrentDueDate to '09/02/2013' 

which would be the next due date (assuming monthly payments) and any CurrentDueDate the same way. I seem to have a mental block and have tried many things, but can't get it right.


Viewing all articles
Browse latest Browse all 23857

Trending Articles