Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 28
Default Transposing from two dimensional to one dimensional

Is there an array formula that will transpose from two dimensional to one
dimensional?
What I need to do is change an Excel database from multiple rows & columns
to one single column, so that I may export it into another database.
I would prefer not to use VBA if I didn't have to, and the formula would
have to allow the number of columns to be calculated either automatically or
manually, as this may vary.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default Transposing from two dimensional to one dimensional

One way

Assuming source data in 4 cols, cols A to D, from row1 down
In E1: =OFFSET($A$1,INT((ROWS($1:1)-1)/4),MOD(ROWS($1:1)-1,4))
Copy E1 down as far as required, until continuous zeros appear signalling
exhaustion of source data

Adapt to suit:
Anchor cell = A1 (ie top left cell in the source data, change as reqd)
No. of cols = 4 (change this number in both INT and MOD parts as reqd)
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:16,000 Files:354 Subscribers:53
xdemechanik
---
"VickiMc" wrote:
Is there an array formula that will transpose from two dimensional to one
dimensional?
What I need to do is change an Excel database from multiple rows & columns
to one single column, so that I may export it into another database.
I would prefer not to use VBA if I didn't have to, and the formula would
have to allow the number of columns to be calculated either automatically or
manually, as this may vary.

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 28
Default Transposing from two dimensional to one dimensional

Thanks Max, that works a treat.
I don't suppose I could impose upon you further and ask if it were possible
to use a range name to determine the number of rows & columns?


"Max" wrote:

One way

Assuming source data in 4 cols, cols A to D, from row1 down
In E1: =OFFSET($A$1,INT((ROWS($1:1)-1)/4),MOD(ROWS($1:1)-1,4))
Copy E1 down as far as required, until continuous zeros appear signalling
exhaustion of source data

Adapt to suit:
Anchor cell = A1 (ie top left cell in the source data, change as reqd)
No. of cols = 4 (change this number in both INT and MOD parts as reqd)
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:16,000 Files:354 Subscribers:53
xdemechanik
---
"VickiMc" wrote:
Is there an array formula that will transpose from two dimensional to one
dimensional?
What I need to do is change an Excel database from multiple rows & columns
to one single column, so that I may export it into another database.
I would prefer not to use VBA if I didn't have to, and the formula would
have to allow the number of columns to be calculated either automatically or
manually, as this may vary.

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default Transposing from two dimensional to one dimensional

"VickiMc" wrote:
Thanks Max, that works a treat.


Welcome. Do press the "Yes" button in that response then, won't you.

I don't suppose I could impose upon you further and ask if it were possible
to use a range name to determine the number of rows & columns?


Array-enter this in any cell outside the defined range MyR,
then copy down as far as required:
=OFFSET(MyR,INT((ROWS($1:1)-1)/COLUMNS(MyR)),MOD(ROWS($1:1)-1,COLUMNS(MyR)))
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:16,000 Files:354 Subscribers:53
xdemechanik
---
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
two dimensional arrays Dave Breitenbach Excel Worksheet Functions 4 September 19th 07 09:12 PM
One dimensional timescale [email protected] Charts and Charting in Excel 2 January 20th 06 02:19 PM
Two dimensional lookup CDog Excel Worksheet Functions 6 November 24th 05 07:58 PM
how do i set up a three dimensional table qadie Excel Discussion (Misc queries) 3 November 2nd 05 05:05 PM
Two dimensional sum by week Jon C Excel Worksheet Functions 6 April 3rd 05 06:10 PM


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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"