spreadsheet is about 15-20k lines usually would like something a bit simpler and maybe more dynamic rather than having to manually adjust for which type of invoice is being deferred in the current month.
type 1 starts in current month, type 2 starts two months out from date.
example scenario:
[TABLE="width: 500"]
<tbody>[TR]
[TD]region[/TD]
[TD]pd[/TD]
[TD]type[/TD]
[TD]type[/TD]
[TD]date[/TD]
[TD]start date[/TD]
[TD]end date[/TD]
[TD]name[/TD]
[TD]amount[/TD]
[TD]# days[/TD]
[TD]daily amt[/TD]
[TD]11/30/15[/TD]
[TD]12/31/15[/TD]
[TD]1/31/16[/TD]
[TD]2/29/16[/TD]
[TD]3/31/16[/TD]
[/TR]
[TR]
[TD]north[/TD]
[TD]2015-11[/TD]
[TD]inv[/TD]
[TD]2[/TD]
[TD]11/15/15[/TD]
[TD]01/01/16[/TD]
[TD]12/31/16[/TD]
[TD]client 1[/TD]
[TD]10000[/TD]
[TD]365[/TD]
[TD]27.40[/TD]
[TD]10000[/TD]
[TD]10000[/TD]
[TD]9178[/TD]
[TD]etc[/TD]
[TD]etc[/TD]
[/TR]
[TR]
[TD]south[/TD]
[TD]2015-11[/TD]
[TD]inv[/TD]
[TD]1[/TD]
[TD]11/15/15[/TD]
[TD]11/1/15[/TD]
[TD]10/31/16[/TD]
[TD]client 2[/TD]
[TD]5000[/TD]
[TD]365[/TD]
[TD]13.70[/TD]
[TD]4603[/TD]
[TD]4178[/TD]
[TD]3753[/TD]
[TD]etc[/TD]
[TD]etc[/TD]
[/TR]
[TR]
[TD]south[/TD]
[TD]2015-11[/TD]
[TD]inv[/TD]
[TD]1[/TD]
[TD]11/15/15[/TD]
[TD]11/1/15[/TD]
[TD]10/31/16[/TD]
[TD]client 3[/TD]
[TD]1000[/TD]
[TD]365[/TD]
[TD]2.74[/TD]
[TD]921[/TD]
[TD]836[/TD]
[TD]751[/TD]
[TD]etc[/TD]
[TD]etc[/TD]
[/TR]
</tbody>[/TABLE]
the current formula is:
=IF($L3>=0,IF(IF($F3>P$2,0,$L3-((P$2-$F3)*$N3))<0,0,IF($F3>P$2,0,$L3-((P$2-$F3)*$N3))),IF(IF($F3>P$2,0,$L3-((P$2-$F3)*$N3))>0,0,IF($F3>P$2,0,$L3-((P$2-$F3)*$N3))))
when i initially put new items in the sheet, i still have to manually adjust the formula to equal the amount for the type 2 invoices for the 1st two months, and then copy out the regular formula for the next 12.
tried some searches but couldnt quite find something that has worked.
thanks in advance!
type 1 starts in current month, type 2 starts two months out from date.
example scenario:
[TABLE="width: 500"]
<tbody>[TR]
[TD]region[/TD]
[TD]pd[/TD]
[TD]type[/TD]
[TD]type[/TD]
[TD]date[/TD]
[TD]start date[/TD]
[TD]end date[/TD]
[TD]name[/TD]
[TD]amount[/TD]
[TD]# days[/TD]
[TD]daily amt[/TD]
[TD]11/30/15[/TD]
[TD]12/31/15[/TD]
[TD]1/31/16[/TD]
[TD]2/29/16[/TD]
[TD]3/31/16[/TD]
[/TR]
[TR]
[TD]north[/TD]
[TD]2015-11[/TD]
[TD]inv[/TD]
[TD]2[/TD]
[TD]11/15/15[/TD]
[TD]01/01/16[/TD]
[TD]12/31/16[/TD]
[TD]client 1[/TD]
[TD]10000[/TD]
[TD]365[/TD]
[TD]27.40[/TD]
[TD]10000[/TD]
[TD]10000[/TD]
[TD]9178[/TD]
[TD]etc[/TD]
[TD]etc[/TD]
[/TR]
[TR]
[TD]south[/TD]
[TD]2015-11[/TD]
[TD]inv[/TD]
[TD]1[/TD]
[TD]11/15/15[/TD]
[TD]11/1/15[/TD]
[TD]10/31/16[/TD]
[TD]client 2[/TD]
[TD]5000[/TD]
[TD]365[/TD]
[TD]13.70[/TD]
[TD]4603[/TD]
[TD]4178[/TD]
[TD]3753[/TD]
[TD]etc[/TD]
[TD]etc[/TD]
[/TR]
[TR]
[TD]south[/TD]
[TD]2015-11[/TD]
[TD]inv[/TD]
[TD]1[/TD]
[TD]11/15/15[/TD]
[TD]11/1/15[/TD]
[TD]10/31/16[/TD]
[TD]client 3[/TD]
[TD]1000[/TD]
[TD]365[/TD]
[TD]2.74[/TD]
[TD]921[/TD]
[TD]836[/TD]
[TD]751[/TD]
[TD]etc[/TD]
[TD]etc[/TD]
[/TR]
</tbody>[/TABLE]
the current formula is:
=IF($L3>=0,IF(IF($F3>P$2,0,$L3-((P$2-$F3)*$N3))<0,0,IF($F3>P$2,0,$L3-((P$2-$F3)*$N3))),IF(IF($F3>P$2,0,$L3-((P$2-$F3)*$N3))>0,0,IF($F3>P$2,0,$L3-((P$2-$F3)*$N3))))
when i initially put new items in the sheet, i still have to manually adjust the formula to equal the amount for the type 2 invoices for the 1st two months, and then copy out the regular formula for the next 12.
tried some searches but couldnt quite find something that has worked.
thanks in advance!