#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
LX
 
Posts: n/a
Default Columns To Rows

Hi,

I have some data which I need some help with converting from columns to
rows. The data is in the format:

Col A Col B
A 1
A 2
A 3
B 4
C 5
C 6

The output will look like:

Col A Col B Col C Col D
A 1 2 3
B 4
C 5 6

Basically, the initial sheet will contain Column A which will be the
identifier and Column B which has unique values for each identifier.
The output I am hoping to get is for each unique identifier such as
"A", get the total number of values (1,2,3) that correspond and place
them into seperate columns as shown above.

Is there a way to achieve the above without writing a macro ??

Thanks

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Marcelo
 
Posts: n/a
Default Columns To Rows

Hi LX,

If you do not talking about tons of rows or different identifier, an easy
way is copy | special past | values | transpose - per group of identifier

as

A 1
A 2
A 3

will

A A A
1 2 3

regards

"LX" escreveu:

Hi,

I have some data which I need some help with converting from columns to
rows. The data is in the format:

Col A Col B
A 1
A 2
A 3
B 4
C 5
C 6

The output will look like:

Col A Col B Col C Col D
A 1 2 3
B 4
C 5 6

Basically, the initial sheet will contain Column A which will be the
identifier and Column B which has unique values for each identifier.
The output I am hoping to get is for each unique identifier such as
"A", get the total number of values (1,2,3) that correspond and place
them into seperate columns as shown above.

Is there a way to achieve the above without writing a macro ??

Thanks


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
LX
 
Posts: n/a
Default Columns To Rows

Hi Marcelo,

Thanks for the help but I do need it in the format:

Col A Col B Col C Col D
A 1 2 3
B 4
C 5 6

This was a simple example but the worksheet I am dealing with has
thousands of rows and many identifiers.

Thanks

Marcelo wrote:
Hi LX,

If you do not talking about tons of rows or different identifier, an easy
way is copy | special past | values | transpose - per group of identifier

as

A 1
A 2
A 3

will

A A A
1 2 3

regards

"LX" escreveu:

Hi,

I have some data which I need some help with converting from columns to
rows. The data is in the format:

Col A Col B
A 1
A 2
A 3
B 4
C 5
C 6

The output will look like:

Col A Col B Col C Col D
A 1 2 3
B 4
C 5 6

Basically, the initial sheet will contain Column A which will be the
identifier and Column B which has unique values for each identifier.
The output I am hoping to get is for each unique identifier such as
"A", get the total number of values (1,2,3) that correspond and place
them into seperate columns as shown above.

Is there a way to achieve the above without writing a macro ??

Thanks



  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Marcelo
 
Posts: n/a
Default Columns To Rows

Sure, create a new colomn left and cut and past the col A like:


Col A Col B Col C Col D
A A A
1 2 3

So,

Col A Col B Col C Col D Col E
A A
A 1 2 3

exclude the first line

hope its help
Marcelo




"LX" escreveu:

Hi Marcelo,

Thanks for the help but I do need it in the format:

Col A Col B Col C Col D
A 1 2 3
B 4
C 5 6

This was a simple example but the worksheet I am dealing with has
thousands of rows and many identifiers.

Thanks

Marcelo wrote:
Hi LX,

If you do not talking about tons of rows or different identifier, an easy
way is copy | special past | values | transpose - per group of identifier

as

A 1
A 2
A 3

will

A A A
1 2 3

regards

"LX" escreveu:

Hi,

I have some data which I need some help with converting from columns to
rows. The data is in the format:

Col A Col B
A 1
A 2
A 3
B 4
C 5
C 6

The output will look like:

Col A Col B Col C Col D
A 1 2 3
B 4
C 5 6

Basically, the initial sheet will contain Column A which will be the
identifier and Column B which has unique values for each identifier.
The output I am hoping to get is for each unique identifier such as
"A", get the total number of values (1,2,3) that correspond and place
them into seperate columns as shown above.

Is there a way to achieve the above without writing a macro ??

Thanks




  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Marcelo
 
Posts: n/a
Default Columns To Rows

Sorry, if you have a thousands of rows this way will not help you..

regards

"Marcelo" escreveu:

Sure, create a new colomn left and cut and past the col A like:


Col A Col B Col C Col D
A A A
1 2 3

So,

Col A Col B Col C Col D Col E
A A
A 1 2 3

exclude the first line

hope its help
Marcelo




"LX" escreveu:

Hi Marcelo,

Thanks for the help but I do need it in the format:

Col A Col B Col C Col D
A 1 2 3
B 4
C 5 6

This was a simple example but the worksheet I am dealing with has
thousands of rows and many identifiers.

Thanks

Marcelo wrote:
Hi LX,

If you do not talking about tons of rows or different identifier, an easy
way is copy | special past | values | transpose - per group of identifier

as

A 1
A 2
A 3

will

A A A
1 2 3

regards

"LX" escreveu:

Hi,

I have some data which I need some help with converting from columns to
rows. The data is in the format:

Col A Col B
A 1
A 2
A 3
B 4
C 5
C 6

The output will look like:

Col A Col B Col C Col D
A 1 2 3
B 4
C 5 6

Basically, the initial sheet will contain Column A which will be the
identifier and Column B which has unique values for each identifier.
The output I am hoping to get is for each unique identifier such as
"A", get the total number of values (1,2,3) that correspond and place
them into seperate columns as shown above.

Is there a way to achieve the above without writing a macro ??

Thanks






  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Herbert Seidenberg
 
Posts: n/a
Default Columns To Rows

Assume your data looks like this,
changed to cover more contingencies:
BinA BinB
A 11
B 12
C 13
A 14
C 15

A 16

BinC 1 2 3 Coln
A 11 14 16
B 12
C 13 15

Name BinA and BinB.
Create BinC with Advanced Filter, unique records, and name it.
Create the horizontal header Coln and name it Coln.
It is a sequence of numbers from 1 to n
n=MAX(COUNTIF(BinA,BinA)) This is an array formula.
Tools Options General R1C1 Ref Style
At the intersection of BinC=A and Coln=1 enter this array formula
=IF(COUNTIF(BinA,BinC R)=Coln C,
SMALL((BinA=BinC R)*BinB,ROWS(BinA)-
COUNTIF(BinA,BinC R)+Coln C),"")
Fill the rest of the array with the fill handle.
Uncheck R1C1 Ref Style.

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
Rows & Columns in Excel seadragon69 Excel Worksheet Functions 2 December 7th 05 05:54 PM
convert columns to rows & rows to columns ROCKWARRIOR Excel Discussion (Misc queries) 2 September 23rd 05 06:31 PM
How to swap rows and columns? [email protected] Excel Discussion (Misc queries) 5 September 21st 05 08:07 AM
hidden rows & columns slow file open Simon Shaw Excel Discussion (Misc queries) 0 April 5th 05 12:21 AM
Removing Near-Duplicate Rows, Leaving Those w/Most Data in Specific Columns foofoo Excel Discussion (Misc queries) 1 April 2nd 05 12:02 AM


All times are GMT +1. The time now is 07:56 AM.

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"