Please find both the procedure here tghe columns named as daystosuggested is calculating different results for the different procedures.
Someone please check and let me know exacly where the problem exists ...
I tried to find it out but not successful yet