Wrox Programmer Forums
Go Back   Wrox Programmer Forums > SQL Server > SQL Server DTS
|
SQL Server DTS Discussion specific to Data Transformation Service with SQL Server. General SQL Server discussions should use the general SQL Server forum. Readers of the book Professional SQL Server 2000 DTS with questions specific to that book should post in that book forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the SQL Server DTS section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old February 25th, 2005, 07:35 AM
Registered User
 
Join Date: Feb 2005
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Default DTS - Importing fixed format files (again)

I have some very 'wide' fixed format files to import (up to 450 fields). The import wizard requires the steady hand and sharp eyes of a 20 year old to get the column positions right. Sadly I am no longer a steady, sharp eyed 20 year old and find this task a serious pain! I'm upgrading from Access so I have the import spec. My question - has anyone found a way of setting up a DTS import package with column start positions as 'parameters'. I've looked at bcp, but it seems to assume delimited files.

Thanks

 
Old February 25th, 2005, 05:07 PM
Friend of Wrox
 
Join Date: Nov 2003
Posts: 625
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to jemacc
Default

A suggestion you make consider

Create a linked server to your access database, insert the records into your new SQL Database.



Jaime E. Maccou
 
Old February 28th, 2005, 11:49 AM
Registered User
 
Join Date: Feb 2005
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks for your suggestion Jaime.
I had a solution from another forum which is to create a table for import with one big field, then use a view with substring's to unpack the data. This worked OK as I was able to clipboard copy the column names, start positions and widths from the Access import spec, then edit in SQL Analyser to make a Create View statement.






Similar Threads
Thread Thread Starter Forum Replies Last Post
Importing Fixed Width .txt Document and Then Some! Diretemus Access VBA 8 March 26th, 2008 07:27 AM
importing files hotshot_21 VB.NET 2002/2003 Basics 0 January 5th, 2006 06:34 AM
DTS Fixed Width File Import rochak SQL Server DTS 3 September 26th, 2005 09:12 AM
Help me on Fixed Field Length data files hossrad SQL Server DTS 3 January 29th, 2005 07:50 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.