Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default Return a value if two other values exist

I am trying to figure out how to set up a formula for the following
example:
Two different worksheets A and B

worksheet A: column A = ID, column b = service type

worksheet B: column A = ID, column b =service type(cleaning), column c
= service type(repair), column C = service type(delivery).

worksheet A can have the same id on multiple rows with a different
type of service for example
id, services ---- column header
123, cleaning
124, cleaning
123, repair
124, delivery

on Worksheet B, I want one id per row like this:
id, cleaning, repair, delivery ------column header
123, yes, yes, no

So baically I want one row per id on worksheet b going across.

Thanks,
Rob

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,104
Default Return a value if two other values exist

Assumptions:
1) data on SheetA goes from 2 to 101 (row 1 having labels)
2) first ID in SheetB is in A2 and row I has labels "ID", "Cleaning",
"Repair", etc

In B2 of SheetB enter
=SUMPRODUCT(--('SheetA'!$A$2:$A$101=$A1),--('SheetA'!$B$2:$B$101=B$1))
Copy across and down the table on SheetB

For more details on SUMPRODUCT
Bob Phillips
http://www.xldynamic.com/source/xld.SUMPRODUCT.html
J.E McGimpsey
http://mcgimpsey.com/excel/formulae/doubleneg.html
Debra Dalgleish
http://www.contextures.com/xlFunctio...tml#SumProduct


Or maybe its time to learn about Pivot Tables
Debra Dalgleish's pictures at Jon Peltier's site:
http://peltiertech.com/Excel/Pivots/pivottables.htm
And Debra's own site:
http://www.contextures.com/xlPivot01.html

John Walkenbach also has some at:
http://j-walk.com/ss/excel/files/general.htm
(look for Tony Gwynn's Hit Database)

Chip Pearson keeps Harald Staff's notes at:
http://www.cpearson.com/excel/pivots.htm

MS has some at (xl2000 and xl2002):
http://office.microsoft.com/downloads/2000/XCrtPiv.aspx
http://office.microsoft.com/assistan...lconPT101.aspx


best wishes

--
Bernard V Liengme
Microsoft Excel MVP
http://people.stfx.ca/bliengme
remove caps from email


"pidoling" wrote in message
...
I am trying to figure out how to set up a formula for the following
example:
Two different worksheets A and B

worksheet A: column A = ID, column b = service type

worksheet B: column A = ID, column b =service type(cleaning), column c
= service type(repair), column C = service type(delivery).

worksheet A can have the same id on multiple rows with a different
type of service for example
id, services ---- column header
123, cleaning
124, cleaning
123, repair
124, delivery

on Worksheet B, I want one id per row like this:
id, cleaning, repair, delivery ------column header
123, yes, yes, no

So baically I want one row per id on worksheet b going across.

Thanks,
Rob


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
How to remove non-exist values in pull-down list in pivot table Terence C Excel Worksheet Functions 1 May 20th 09 09:20 AM
Want a trace a same values exist in two different sheet Mukesh Excel Worksheet Functions 2 April 23rd 09 12:56 PM
How do I return a unique count where conditions exist? Cher Excel Worksheet Functions 4 June 20th 08 06:00 PM
filtering data to include values only if x and y exist Hans Excel Discussion (Misc queries) 4 November 5th 07 06:51 AM
Returning the desired value if multiple values exist???? njuneardave Excel Worksheet Functions 1 June 21st 06 08:32 PM


All times are GMT +1. The time now is 11:46 PM.

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

About Us

"It's about Microsoft Excel"