Get blocks of cells from horizontal to vertical direction

L

Legacy 402423

Guest
Hi Guys,

What is the case? I am trying to help a friend of mine, but I do not get there.... I tried R1C1 and transpose, but I don't get things how I want them.
The starting point is as following: an excelsheet is retrieved from a database. The database allows only 1 format for exporting.
On the vertical axis are the years (2006-2015) and on the horizontal axis hunderds of companies with each having 17 columns each containing 1 financial value (say net profit).

What I want is all years of all companies below each other, such that I have only 17 columns (years are not important in the end) and in each column all values of all companies for all years for that specific financial number.

So now it looks like:
Years | ProfitA | DebtA | ... | ProfitB | DebtB| ...
2005 | X | X | X | X | X | X ...
200.. | X | X | X | X | X | X ...
2016 | X | X | X | X | X | X ...

And I want it like this:
Profit | Debt | ....
A2005 | A2005 | ...
A20.. | A20.. | ...
A20016 | A2016 | ...
B2005 | B2005 | ...

and so on...

Why do I want this to go automatically? Because the database contains thousands of companies... :eeek:

Has anybody an idea?
 

Excel Facts

Which Excel functions can ignore hidden rows?
The SUBTOTAL and AGGREGATE functions ignore hidden rows. AGGREGATE can also exclude error cells and more.
May be this painting make things a bit more clear ;)

accf26777ed748fd91f8fad304bd4055.png
 
Upvote 0
I don't think anyone has any problem with the concept of transposition. ;) ;) ;)

What is far from clear is the actual layout of your data. Provide a more detailed sample table for us to use.
 
Upvote 0
What is far from clear is the actual layout of your data. Provide a more detailed sample table for us to use.

I will give it a try ;)

Where The capital letters represent different firms (A,B,C). Profit, debt and ... represent around 10 characteristics of each firm.
For all characteristics and each firm I have the data from 2006-2015

[TABLE="class: grid, width: 800"]
<tbody>[TR]
[TD]Year[/TD]
[TD]Profit (A)[/TD]
[TD]Debt (A)[/TD]
[TD]...(A)[/TD]
[TD]Profit (B)[/TD]
[TD]Debt (B)[/TD]
[TD]... (B)[/TD]
[TD]Profit (C)[/TD]
[TD]...[/TD]
[TD]...[/TD]
[/TR]
[TR]
[TD]2006[/TD]
[TD]X[/TD]
[TD]X[/TD]
[TD]X
[/TD]
[TD]X[/TD]
[TD]X[/TD]
[TD]X[/TD]
[TD]X[/T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]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]A2016[/TD]
[TD]A2016[/TD]
[TD]A2016[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]B2005[/TD]
[TD]B2005[/TD]
[TD]B2005[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]B2006[/TD]
[TD]B2006[/TD]
[TD]B2006[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]B20..[/TD]
[TD]B20..[/TD]
[TD]B20..[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]B2016[/TD]
[TD]B2016[/TD]
[TD]B2016[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]C...[/TD]
[TD]C...[/TD]
[TD]C...[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
 
Upvote 0
Can you provide some more realistic sample data? What you have given us is still somewhat cryptic.
 
Upvote 0

Forum statistics

Threads
1,223,236
Messages
6,170,917
Members
452,366
Latest member
TePunaBloke

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top