February 12, 2007 at 4:20 pm
How do I import data from excel via DTS but importing the columns as rows and rows as the columns?
February 12, 2007 at 5:26 pm
Dunno... If faced with such a problem, I'd have the spreadsheet do a transpose and write to a text file for me... then, I'd import the text file using Bulk Insert or BCP.
--Jeff Moden
Change is inevitable... Change for the better is not.
February 14, 2007 at 1:11 am
I do this every week, I use an Access project FE where I use ADO code to convert from columns to rows. Try not to refer to your columns directly except for key columns use a numerical index i.e rst(i) where i is a for next variable, that way makes the code flexible and if the number of columns are extended then your time amending the code will be drastically reduced.
Being a programmer I always opt for the easy solution. Ican be done with a query/view for each column but this approach is very inflexible.
February 20, 2007 at 2:46 pm
Did somebody try to play with PIVOT and UNPIVOT in SQL Server 2005? You probably can UNPIVOT the original data and then PIVOT them differently.
Regards,Yelena Varsha
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply