Looping to move data

0

Is there a simple way (without macro/vba) to move data on multiple rows for a common field to a single row, using multiple columns, For example, see INPUT and OUTPUT below; columns b and c of the second row are moved to d and e (then f and g, etc.) of the first row if column a has the same value as the previous row.  ie multiple lines per agent are converted to a single line per agent.

eg

 INPUT

a1   b1   c1

a2   b2   c2           

a3   b3   c3

a3   b4   c4           

a3   b5   c5           

a6   b6   c6           

a7   b7   c7           

a7   b8   c8           

a9   b9   c9           

a10   b10   c10                         

OUTPUT               

a1   b1   c1           

a2   b2   c2           

a3   b3   c3   b4   c4   b5   c5   

a6   b6   c6           

a7   b7   c7   b8   c8       

a9   b9   c9           

a10   b10   c10         

Answer
Discuss

Answers

0

Based on the limited info provided, the best quick solution I can offer is a Pivot Table.  It will have your info, but displayed a bit different than your request (but you could modify it after this).

The attached pivot table actually has Column headings (a really good idea) and it will show 'multiples' of say your "a3'.

Good luck

Discuss

Answer the Question

You must create an account to use the forum. Create an Account or Login