Prorate A Monthly Charge To Daily For A Partial Month
I'm using SQL Server and SSRS. I have a table with a monthly charge for a service. I need to be able to calculate what the charge is for a partial month. I need the monthly charge
Solution 1:
You can get the total number of days for current month by:
SELECTDAY(EOMONTH(DateColumn))
FROMTABLEAnd in your case, I am guessing the query should look like:
SELECT TotalCharges *1.0/DAY(EOMONTH(DateColumn))
FROMTABLE
Post a Comment for "Prorate A Monthly Charge To Daily For A Partial Month"