Tech
Forums
Jobs
Books
Events
Interviews
Live
More
Learn
Training
Career
Members
Videos
News
Blogs
Login
Sign Up
Ask Question
1
Reply
How to get the Year Period as per the currentDate(GetDate())
basit khan
Feb 19 2017 5:00 AM
321
Reply
Hi,
How to get the Year Period as per the currentDate(GetDate()) depend upon Joining Date.
For Example.
Emp_No Joining Date As per todaycurrentDate(His One year period End)
1 14-Jul-2013 14-Jul-2017
2 14-Jul-2016 14-Jul-2017
3 01-Feb-2015 01-Feb-2017
How to do the query?
I use the case but this one will not suite.
CASE WHEN JoinDate < GetDate() THEN dateadd(DAY , 365 , JoinDate) ELSE 0 END
Thanks
Basit.
Upload Source Code
Select only zip and rar file.
Post
Reset
Cancel
Answers (
1
)
Next Recommended Forum
Connectivity problem
Show this month and next month