Thanks:  0
Likes:  0

1. Hi,

I am running a spreadsheet to check amount of fuel put into the company vehicles. I have a number of columns, but the ones that I need are Reg. No and Total Input. Now, I would like to set something up that will automatically calculate the total fuel input of a particular reg. To illustrate:

Reg: Input:
R717 25
S283 34
R716 18
R717 25
S283 34
R716 18

Total (I would prefer this to be in another worksheet)

Reg: Total Input:
R717 50
S283 68
R716 36

However, there are about 17 vans, and I already have nearly 200 entries for the month of April, as they fill up perhaps twice a day. It is probably very easy - I hope so anyway - can anyone help me?

Cheers.

Markus.

2. I'd suggest to have a look at PivotTables.

SUMIF would also do the job.

Lets say that A1:B7 in Sheet1 houses the sample you provided:

{"Reg. No","amount";
"R717",25;
"S283",34;
"R716",18;
"R717",25;
"S283",34;
"R716",18}

Create a unique list of Reg. No's in a second sheet, in A from A2 on like this:

{"Reg. No";
"R717";
"S283";
"R716"}

In B2 enter and copy down:

=SUMIF(Sheet1!\$A\$2:\$A\$7,A2,Sheet1!\$B\$2:\$B\$7)

3. ## I have a question about the formula

I have a similar situation and your formula definately helped me.

I used your formula to grab a certain price in A2 through A6400 then to find the amount of gallons that were sold at that price B2 through B6400

Instead of typing in a new formula for each new/old price I would like to be able to... in my total cell type in a price and have it find the all the gallons relating to that specific price. I have price changes that range in the hundreds.

I have searched high and low from MS website to online forums and seraches and I cannot find away to do this with excel.

Thanks and I hope this is the right spot for this.

4. usually best to start a new thread, dbut as we're here...

have you tried out a filter? (data | filter)

with a 'normal' filter, just set up the filter then go to the custom... option & pick your value

with an advanced filter, you can put the results to a new area if you want to 'extract' the results, not just view them in situ.

review the excel help file topic for 'Filter a list by using advanced criteria'

5. Jeff,

Try A Pivot Table as Aladin suggested. It's not that difficult and the ways your data set is, it shouldn't be a problem, I'll try and find a link for PT tutorials..

http://www.peltiertech.com/Excel/Pivots/pivottables.htm

## User Tag List

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•