Transform data

esbencito

New Member
Joined
May 22, 2017
Messages
16
Hi all,

I need to transform/ re-arrange data in Access. Below table illustrates the data that I currently have:

YearFY18FY18FY18FY18
MonthMARMARFEBFEB
CountryChannelBrandItem NumberSLS UNTSLS CSTSLS UNTSLS CST
ChinaRLSMSW1000434$87.0056$80.00
VietnamRLEMSW1000632$76.0045$92.00
ChinaRLCWSW1000929$97.0047$71.00
ThailandRLSWSW1000817$65.0050$83.00
SingaporeRLCCSW100030038$91.00

<tbody>
</tbody>

In order to pivot it, I want it to look like this:

YearMonthCountryChannelBrandItem NumberSLS UNTSLS CST
FY18MARChinaRLSMSW1000434$87.00
FY18FEBChinaRLSMSW1000456$80.00
FY18MARVietnamRLEMSW1000632$76.00
FY18FEBVietnamRLEMSW1000645$92.00
FY18MARChinaRLCWSW1000929$97.00
FY18FEBChinaRLCWSW1000947$71.00
FY18MARThailandRLSWSW1000817$65.00
FY18FEBThailandRLSWSW1000850$83.00
FY18FEBSingaporeRLCCSW1000338$91.00

<tbody>
</tbody>

Is this feasible somehow?
 
Last edited:

Excel Facts

Test for Multiple Conditions in IF?
Use AND(test, test, test, test) or OR(test, test, test, ...) as the logical_test argument of IF.
Hi,

Your first table is not a valid Access table (it has empty cells in the top left corner and seemingly two column header rows which is not a valid table structure. Are you saying you want to import the data into Access from (possibly) Excel?

Also, the data is already pivoted in table 1 so it isn't clear why you would need to do this to pivot the data. Are you sure you need to do this in Access?
 
Upvote 0
You're right, I get the raw data in table 1 in an Excel file (it is not a pivot though). I have not yet tried to import it into Access, as I first want to figure out what's the best approach to transform the data in order to create a meaningful pivot table (which should then look something like table 1).

I currently cannot create a pivot table from table 1 unless I combine FY18 & MAR & SLS UNT into one column header, but then I wouldn't be able to filter by Year or Month anymore. So I need to somehow transform the data into table 2... :rolleyes:
 
Upvote 0
This super useful!! Thanks for sharing! Unfortunately, it won't work in my case, as the data exceeds 1,000,000 rows once it is transformed as seen in table 2, so it would have to be done in Access I guess :rolleyes:
 
Upvote 0
I think Excel could handle 1,000,000 rows, most likely. It doesn't exceed the row limit, in any case.
 
Upvote 0

Forum statistics

Threads
1,213,546
Messages
6,114,253
Members
448,556
Latest member
peterhess2002

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