ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Adding sales from a non working day to the previous working day (https://www.excelbanter.com/excel-programming/277432-adding-sales-non-working-day-previous-working-day.html)

Alex

Adding sales from a non working day to the previous working day
 
Hi

I have a spreadsheet that contains daily sales data. Very occasionally, we
have sales recorded against a non working day. What I want to do is to add
these sales to the previous working day as if they were actually taken on
that day.

Example:

This could be the data I start with:

Date Sales
15/09/03 $100
16/09/03 $150
17/09/03 $120
18/09/03 $130
19/09/03 $180
21/09/03 $110
22/09/03 $250

I want to translate this to:

Date Sales
15/09/03 $100
16/09/03 $150
17/09/03 $120
18/09/03 $130
19/09/03 $290
22/09/03 $250

(notice that sales for the Sunday 21st have been added to the 19th)

Any ideas how I can achieve this? I've started to use Vlookup against a
static range that only contains working dates, and this will return the
previous value in the range if the exact value doesn't exist, (so the Sales
on the 21st will return the value 18/09/03) but after that I got stuck.

Thanks in advance

Alex



Alex

Adding sales from a non working day to the previous working day
 
Don't worry - I've figured it out after discovering the SUMIF function!


"Alex" <@ wrote in message ...
Hi

I have a spreadsheet that contains daily sales data. Very occasionally,

we
have sales recorded against a non working day. What I want to do is to

add
these sales to the previous working day as if they were actually taken on
that day.

Example:

This could be the data I start with:

Date Sales
15/09/03 $100
16/09/03 $150
17/09/03 $120
18/09/03 $130
19/09/03 $180
21/09/03 $110
22/09/03 $250

I want to translate this to:

Date Sales
15/09/03 $100
16/09/03 $150
17/09/03 $120
18/09/03 $130
19/09/03 $290
22/09/03 $250

(notice that sales for the Sunday 21st have been added to the 19th)

Any ideas how I can achieve this? I've started to use Vlookup against a
static range that only contains working dates, and this will return the
previous value in the range if the exact value doesn't exist, (so the

Sales
on the 21st will return the value 18/09/03) but after that I got stuck.

Thanks in advance

Alex






All times are GMT +1. The time now is 08:15 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com