Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 516
Default advanced paste special transpose

I have some data in the following format:
TTL VAL
A 1
A 2
A 3
B 1
B 2
B 3
C 1
C 2
C 3
and i want it into this format...
A 123
B 123
C 123

any suggestions. the only reason this is so difficult is becasue i need to
do it a formula as i have over 300 000 records over 4 different excel
worksheets.

Thnx

-Matt
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 9,101
Default advanced paste special transpose


Sub combine_rows()

RowCount = 1
Do While Range("A" & RowCount) < ""
If Range("A" & RowCount) = Range("A" & (RowCount + 1)) Then
Range("B" & RowCount) = Trim(Range("B" & RowCount)) & _
Trim(Range("B" & (RowCount + 1)))
Rows(RowCount + 1).Delete
Else
RowCount = RowCount + 1
End If
Loop


End Sub

"Matt" wrote:

I have some data in the following format:
TTL VAL
A 1
A 2
A 3
B 1
B 2
B 3
C 1
C 2
C 3
and i want it into this format...
A 123
B 123
C 123

any suggestions. the only reason this is so difficult is becasue i need to
do it a formula as i have over 300 000 records over 4 different excel
worksheets.

Thnx

-Matt

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,718
Default advanced paste special transpose

In D2:
=IF(ISERR(SMALL(IF(MATCH(TTL,TTL,0)=ROW(INDIRECT(" 1:"&ROWS(TTL))),MATCH(TTL,TTL,0)),ROWS($1:1))),"", INDEX(TTL,SMALL(IF(MATCH(TTL,TTL,0)=ROW(INDIRECT(" 1:"&ROWS(TTL))),MATCH(TTL,TTL,0)),ROWS($1:1))))

ctrl+shift+enter, not just enter
copy down as far as needed

In E2:
=IF(ISERR(SMALL(IF(TTL=$D2,ROW(INDIRECT("1:"&ROWS( VAL)))),COLUMNS($E:E))),"",INDEX(VAL,SMALL(IF(TTL= $D2,ROW(INDIRECT("1:"&ROWS(VAL)))),COLUMNS($E:E))) )

ctrl+shift+enter, not just enter
copy across and down as far as needed



"Matt" wrote:

I have some data in the following format:
TTL VAL
A 1
A 2
A 3
B 1
B 2
B 3
C 1
C 2
C 3
and i want it into this format...
A 123
B 123
C 123

any suggestions. the only reason this is so difficult is becasue i need to
do it a formula as i have over 300 000 records over 4 different excel
worksheets.

Thnx

-Matt

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
paste special transpose problem confused Excel Discussion (Misc queries) 2 November 16th 07 03:49 PM
Transpose, Paste Special idgity Excel Discussion (Misc queries) 2 September 6th 07 06:04 PM
Paste Special / transpose Ron Carr Excel Discussion (Misc queries) 2 February 24th 06 06:13 PM
When I special paste and transpose.... sml New Users to Excel 4 January 12th 06 12:49 AM
Paste Special - Values - Transpose J Excel Worksheet Functions 2 December 6th 05 04:25 PM


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