#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2
Default IF STATEMENT HELP

What I have, some duplicate ID's and some non-duplicate ID's. Need to sum the
amount from two rows and identify the duplicate record in a new column
ID Hours Qtr Gross Qtr
00293 0.50 30.50
00337 170.40 10,574.39
00337 124.00 7,642.49
00443 190.25 12,131.18
00443 132.00 8,140.27
00467 14.00 854.05
00467 3.00 184.27
00913 710.75 45,124.94
00913 166.00 10,242.38
01234 3.55 220.18

What I want

ID Hours Qtr Gross Qtr Grand Total Gross By ID
00293 0.50 30.50 30.5
00337 170.40 10,574.39 18216.88
00337 124.00 7,642.49 Duplicate
00443 190.25 12,131.18 20271.45
00443 132.00 8,140.27 Duplicate
00467 14.00 854.05 1038.32
00467 3.00 184.27 Duplicate
00913 710.75 45,124.94 55367.32
00913 166.00 10,242.38 Duplicate
01234 3.55 220.18 220.18

Any suggestions?
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 65
Default IF STATEMENT HELP

Here is a thought until a better solution comes along.

1.Add a column that has duplicate in every cell beside your data table.
2.Use VLOOKUP formula in the empty end column to identify duplicates by
searching only for items above it. If it finds the item have it give you the
value of the column with duplicates in it. If it does not find a duplicated
number you get an error message.
3.Then insert the column where you want your added sums or "duplicate"
listed. 4.Here insert an "if" formula that equals "Duplicate" if it finds it
in the VLOOKUP column or sums items for a tota if it does not find
"Duplicate".
5.Hide the columns you do not want in your report before printing.

Hope this helps.

"ksummers" wrote:

What I have, some duplicate ID's and some non-duplicate ID's. Need to sum the
amount from two rows and identify the duplicate record in a new column
ID Hours Qtr Gross Qtr
00293 0.50 30.50
00337 170.40 10,574.39
00337 124.00 7,642.49
00443 190.25 12,131.18
00443 132.00 8,140.27
00467 14.00 854.05
00467 3.00 184.27
00913 710.75 45,124.94
00913 166.00 10,242.38
01234 3.55 220.18

What I want

ID Hours Qtr Gross Qtr Grand Total Gross By ID
00293 0.50 30.50 30.5
00337 170.40 10,574.39 18216.88
00337 124.00 7,642.49 Duplicate
00443 190.25 12,131.18 20271.45
00443 132.00 8,140.27 Duplicate
00467 14.00 854.05 1038.32
00467 3.00 184.27 Duplicate
00913 710.75 45,124.94 55367.32
00913 166.00 10,242.38 Duplicate
01234 3.55 220.18 220.18

Any suggestions?

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,718
Default IF STATEMENT HELP

Try this:

=IF(COUNTIF($A$2:A2,A2)=1,SUMIF($A$2:$A$11,A2,$C$2 :$C$11),"Duplicate")

copy down


"ksummers" wrote:

What I have, some duplicate ID's and some non-duplicate ID's. Need to sum the
amount from two rows and identify the duplicate record in a new column
ID Hours Qtr Gross Qtr
00293 0.50 30.50
00337 170.40 10,574.39
00337 124.00 7,642.49
00443 190.25 12,131.18
00443 132.00 8,140.27
00467 14.00 854.05
00467 3.00 184.27
00913 710.75 45,124.94
00913 166.00 10,242.38
01234 3.55 220.18

What I want

ID Hours Qtr Gross Qtr Grand Total Gross By ID
00293 0.50 30.50 30.5
00337 170.40 10,574.39 18216.88
00337 124.00 7,642.49 Duplicate
00443 190.25 12,131.18 20271.45
00443 132.00 8,140.27 Duplicate
00467 14.00 854.05 1038.32
00467 3.00 184.27 Duplicate
00913 710.75 45,124.94 55367.32
00913 166.00 10,242.38 Duplicate
01234 3.55 220.18 220.18

Any suggestions?

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2
Default IF STATEMENT HELP

You are a genius, thank you very much !!!!

"Teethless mama" wrote:

Try this:

=IF(COUNTIF($A$2:A2,A2)=1,SUMIF($A$2:$A$11,A2,$C$2 :$C$11),"Duplicate")

copy down


"ksummers" wrote:

What I have, some duplicate ID's and some non-duplicate ID's. Need to sum the
amount from two rows and identify the duplicate record in a new column
ID Hours Qtr Gross Qtr
00293 0.50 30.50
00337 170.40 10,574.39
00337 124.00 7,642.49
00443 190.25 12,131.18
00443 132.00 8,140.27
00467 14.00 854.05
00467 3.00 184.27
00913 710.75 45,124.94
00913 166.00 10,242.38
01234 3.55 220.18

What I want

ID Hours Qtr Gross Qtr Grand Total Gross By ID
00293 0.50 30.50 30.5
00337 170.40 10,574.39 18216.88
00337 124.00 7,642.49 Duplicate
00443 190.25 12,131.18 20271.45
00443 132.00 8,140.27 Duplicate
00467 14.00 854.05 1038.32
00467 3.00 184.27 Duplicate
00913 710.75 45,124.94 55367.32
00913 166.00 10,242.38 Duplicate
01234 3.55 220.18 220.18

Any suggestions?

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Embedding an OR statement in an IF statement efficiently Chatnoir11 Excel Discussion (Misc queries) 4 February 2nd 09 08:12 PM
If statement or lookup statement not sure Renegade40 Excel Worksheet Functions 2 January 18th 09 06:11 AM
Sum if statement with a left statement Eric D Excel Discussion (Misc queries) 4 July 23rd 08 05:31 PM
appending and IF statement to an existing IF statement spence Excel Worksheet Functions 1 February 28th 06 11:00 PM
If statement and Isblank statement Rodney C. Excel Worksheet Functions 0 January 18th 05 08:39 PM


All times are GMT +1. The time now is 05:23 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"