Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default Not sure what the best function should be.

I want a function that will put a cost amount in the Cost column based on
Plan type; for example if Plan=C then cost will be 6.17 if Plan=A then cost
will be 7.10.

I am not sure if this should be an IF(OR) statement or some other function
and how to write that function.

example

Item Plan Cost
xxx C 6.17
xxx A
xxx C
xxx A
xxx C

Thanks in advance
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,939
Default Not sure what the best function should be.

I assume that somewhere you have or can create a table of the Plans and their
associated costs. At that point I would be inclined to use a Vlookup or
Index/Match formula.
--
HTH...

Jim Thomlinson


"Jose'" wrote:

I want a function that will put a cost amount in the Cost column based on
Plan type; for example if Plan=C then cost will be 6.17 if Plan=A then cost
will be 7.10.

I am not sure if this should be an IF(OR) statement or some other function
and how to write that function.

example

Item Plan Cost
xxx C 6.17
xxx A
xxx C
xxx A
xxx C

Thanks in advance

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,856
Default Not sure what the best function should be.

If you can only have A or C in the Plan column, then this would be
simple:

=IF(B2="C",6.17,7.1)

and you could extend this quite easily if you had a few more
acceptable values. If there is some relationship between the Plan
value and the Cost value, then you could calculate it.

However, if you had more variables in the Plan column, then you could
think about building up a 2-column table somewhere that had the Cost
associated with each variable, and then you could use VLOOKUP.

Hope this helps.

Pete

On Sep 23, 4:24*pm, Jose' wrote:
I want a function that will put a cost amount in the Cost column based on
Plan type; for example if Plan=C then cost will be 6.17 if Plan=A then cost
will be 7.10. *

I am not sure if this should be an IF(OR) statement or some other function
and how to write that function.

example

*Item * *Plan * *Cost
*xxx * * C * * * * * * *6.17 * *
*xxx * * A * * *
*xxx * * C * * *
*xxx * * A * * *
*xxx * * C * * *

Thanks in advance


  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default Not sure what the best function should be.

Hi,

One way. Change the values to suit

=LOOKUP(B2,{"A","B","C","D"},{1.5,2.5,3.7,4.9})

In practice you could use cell references for the values

=LOOKUP(B3,{"A","B","C","D"},$K$1:$K$4)

Mike

Mike

"Jose'" wrote:

I want a function that will put a cost amount in the Cost column based on
Plan type; for example if Plan=C then cost will be 6.17 if Plan=A then cost
will be 7.10.

I am not sure if this should be an IF(OR) statement or some other function
and how to write that function.

example

Item Plan Cost
xxx C 6.17
xxx A
xxx C
xxx A
xxx C

Thanks in advance

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2
Default Not sure what the best function should be.

Thanks Jim:

Yes, I guess I could do it that way, because I only have two cost I am
dealing with 6.17 and 7.10 - I thought it would be more efficient to write a
formula.

Jose'

"Jim Thomlinson" wrote:

I assume that somewhere you have or can create a table of the Plans and their
associated costs. At that point I would be inclined to use a Vlookup or
Index/Match formula.
--
HTH...

Jim Thomlinson


"Jose'" wrote:

I want a function that will put a cost amount in the Cost column based on
Plan type; for example if Plan=C then cost will be 6.17 if Plan=A then cost
will be 7.10.

I am not sure if this should be an IF(OR) statement or some other function
and how to write that function.

example

Item Plan Cost
xxx C 6.17
xxx A
xxx C
xxx A
xxx C

Thanks in advance



  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2
Default Not sure what the best function should be.

Pete... EXCELLENT... This is what I was looking for... THANK YOU !!!

Jose
--
So many spreadsheets and so little time. ----- Jose''


"Pete_UK" wrote:

If you can only have A or C in the Plan column, then this would be
simple:

=IF(B2="C",6.17,7.1)

and you could extend this quite easily if you had a few more
acceptable values. If there is some relationship between the Plan
value and the Cost value, then you could calculate it.

However, if you had more variables in the Plan column, then you could
think about building up a 2-column table somewhere that had the Cost
associated with each variable, and then you could use VLOOKUP.

Hope this helps.

Pete

On Sep 23, 4:24 pm, Jose' wrote:
I want a function that will put a cost amount in the Cost column based on
Plan type; for example if Plan=C then cost will be 6.17 if Plan=A then cost
will be 7.10.

I am not sure if this should be an IF(OR) statement or some other function
and how to write that function.

example

Item Plan Cost
xxx C 6.17
xxx A
xxx C
xxx A
xxx C

Thanks in advance



  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,856
Default Not sure what the best function should be.

You're welcome, Jose - thanks for feeding back.

Pete

On Sep 23, 4:46*pm, Jose'' wrote:
Pete... * EXCELLENT... This is what I was looking for... * THANK YOU !!!

Jose
--
So many spreadsheets and so little time. * * ----- Jose''



"Pete_UK" wrote:
If you can only have A or C in the Plan column, then this would be
simple:


=IF(B2="C",6.17,7.1)


and you could extend this quite easily if you had a few more
acceptable values. If there is some relationship between the Plan
value and the Cost value, then you could calculate it.


However, if you had more variables in the Plan column, then you could
think about building up a 2-column table somewhere that had the Cost
associated with each variable, and then you could use VLOOKUP.


Hope this helps.


Pete


On Sep 23, 4:24 pm, Jose' wrote:
I want a function that will put a cost amount in the Cost column based on
Plan type; for example if Plan=C then cost will be 6.17 if Plan=A then cost
will be 7.10. *


I am not sure if this should be an IF(OR) statement or some other function
and how to write that function.


example


*Item * *Plan * *Cost
*xxx * * C * * * * * * *6.17 * *
*xxx * * A * * *
*xxx * * C * * *
*xxx * * A * * *
*xxx * * C * * *


Thanks in advance- Hide quoted text -


- Show quoted text -


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
Excel Data Validation/Lookup function does function correcty Kirkey Excel Worksheet Functions 2 May 25th 09 09:22 PM
copy of excel file not showing formulal/function in the function b oaallam Excel Discussion (Misc queries) 4 September 6th 07 01:20 PM
LINKEDRANGE function - a complement to the PULL function (for getting values from a closed workbook) [email protected] Excel Worksheet Functions 0 September 5th 06 03:44 PM
Offset function with nested match function not finding host ss. MKunert Excel Worksheet Functions 1 March 21st 06 10:46 PM
Emulate Index/Match combo function w/ VBA custom function Spencer Hutton Excel Worksheet Functions 2 May 2nd 05 05:26 PM


All times are GMT +1. The time now is 10:04 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"