Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Ascii Files


Ascii Files

Author
Message
SQL_Buddy99
SQL_Buddy99
SSC Rookie
SSC Rookie (26 reputation)SSC Rookie (26 reputation)SSC Rookie (26 reputation)SSC Rookie (26 reputation)SSC Rookie (26 reputation)SSC Rookie (26 reputation)SSC Rookie (26 reputation)SSC Rookie (26 reputation)

Group: General Forum Members
Points: 26 Visits: 398
Hello EveryOne,
I need some help from you all.

I am trying to build a package where the requirement goes like this.

There is text file which consits of just the column names, so here I am dumping this data into a particular table in DB and running a procedure which takes this dumped data and creates the tables accordingly, which in later has to be loaded with ASCII file data.

So here comes the problem, we are getting a bunch of files (.asc files) which doesn't have the column names in it, It just got the data in it.

There are totally 5 different regions, for one region I am getting the files having same number of columns in every file. But for other 4 regions I am getting the files that have different number of columns in each file.

So here I am taking a foreach loop and a DFT. In DFT I am taking a FlatFile source and oledb destination. In the FlatFile Source the connection manager I have chosen Fixed Width Format and in the columns tab I am manually selected all the columns.

So these foreach loop works fine if all the files have the same number of columns. but it doesn't if it has different number of columns in the files.

So could you all please give your valuable suggestions how to handle these files which doesn't have the column names.

Thanks every one
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search