#1   Report Post  
neil
 
Posts: n/a
Default Summing values

Hi,

I have several columns of data in the format "nnt" where n= numeric value,
t=text.

I need to sum up the numeric values, based on the text value.

Is there any way I can do this?

Thanks for the help.
  #2   Report Post  
Peo Sjoblom
 
Posts: n/a
Default

You need to give us more information, is it always 2 digits and one text
character or can there be more than one text character? What would the
condition be. For a test assume there is always one text character and
always at the end

12t
1n
24t
9t
16n

assume you want to sum all the numeric values that ends with the text
character t

=SUMPRODUCT(--(RIGHT(A1:A5)="t"),--(SUBSTITUTE(A1:A5,RIGHT(A1:A5),"")))

will return 45

--
Regards,

Peo Sjoblom

(No private emails please)


"neil" wrote in message
...
Hi,

I have several columns of data in the format "nnt" where n= numeric value,
t=text.

I need to sum up the numeric values, based on the text value.

Is there any way I can do this?

Thanks for the help.


  #3   Report Post  
Mangesh Yadav
 
Posts: n/a
Default

Suppose the column in question is A, then use the following formula:
=SUMPRODUCT(--(RIGHT(A1:A4,1)="a"),INT(LEFT(A1:A4,2)))

I have assumed:
A1 = 22a
A2 = 23b
A3 = 24a
A4 = 25c

Teh above formula returns 46 for t = a

Mangesh


"neil" wrote in message
...
Hi,

I have several columns of data in the format "nnt" where n= numeric value,
t=text.

I need to sum up the numeric values, based on the text value.

Is there any way I can do this?

Thanks for the help.



  #4   Report Post  
neil
 
Posts: n/a
Default

Thanks, works like a charm.

Can this be modified to count how many instances of the text value appears?
For instance, a countif based on "a"?

Regards

"Mangesh Yadav" wrote:

Suppose the column in question is A, then use the following formula:
=SUMPRODUCT(--(RIGHT(A1:A4,1)="a"),INT(LEFT(A1:A4,2)))

I have assumed:
A1 = 22a
A2 = 23b
A3 = 24a
A4 = 25c

Teh above formula returns 46 for t = a

Mangesh


"neil" wrote in message
...
Hi,

I have several columns of data in the format "nnt" where n= numeric value,
t=text.

I need to sum up the numeric values, based on the text value.

Is there any way I can do this?

Thanks for the help.




  #5   Report Post  
Mangesh Yadav
 
Posts: n/a
Default

=SUMPRODUCT(--(RIGHT(A1:A4,1)="a"))

Mangesh


"neil" wrote in message
...
Thanks, works like a charm.

Can this be modified to count how many instances of the text value

appears?
For instance, a countif based on "a"?

Regards

"Mangesh Yadav" wrote:

Suppose the column in question is A, then use the following formula:
=SUMPRODUCT(--(RIGHT(A1:A4,1)="a"),INT(LEFT(A1:A4,2)))

I have assumed:
A1 = 22a
A2 = 23b
A3 = 24a
A4 = 25c

Teh above formula returns 46 for t = a

Mangesh


"neil" wrote in message
...
Hi,

I have several columns of data in the format "nnt" where n= numeric

value,
t=text.

I need to sum up the numeric values, based on the text value.

Is there any way I can do this?

Thanks for the help.








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
What is the best method for summing values where you want 2 value. Susan F. Excel Discussion (Misc queries) 2 March 25th 05 07:03 PM
Summing Related Values Adam1 Chicago Excel Discussion (Misc queries) 1 March 9th 05 09:38 PM
searching for values and summing the corresponding values Simon Excel Worksheet Functions 1 February 4th 05 12:13 AM
Summing Values from different workbooks Harlan Grove Excel Discussion (Misc queries) 0 November 26th 04 07:38 PM
Summing values of corresponding columns lanceg Excel Worksheet Functions 2 November 5th 04 05:41 AM


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