View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
[email protected] nickwalker1@gmail.com is offline
external usenet poster
 
Posts: 1
Default Multiple rows from a single row

Hi,
I've got a worksheet with the following data (for example).
ID, Field 1, Field 2
1, hello, world
2, here, again

I'm looking to put it in the format

ID, FieldName, FieldValue
1, Field1, hello
1, Field2, world
2, Field1, here
2, Field2, again

As you can see I'm mapping the column headers into row values (column
2) and thier related value into row values (column3). For each
combination I've got to repeat the row ID.

I think this can only be done via a macro? Is this right..and can you
help (in reality I've got about 25 different fields and the number of
rows is variable)??

Thanks in advance
Nick