[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

SSIS to create text file

Posted on 2013-01-28
5
Medium Priority
?
332 Views
Last Modified: 2016-02-10
I have a new wages exports process.

I need to export data to a text file for import into paycor

The text file consists of a header record (1 line)
detail records (however many employees...one per)
trailer record (1 line)

I have no problem creating the data....
However, I'm supposed to build this in SSIS.

So...in SSIS, should I build the three records seperately and then appeand the detail and the trailer record to the header?

Or Build the whole thing in sql itself?

need some direction in this.
0
Comment
Question by:lrbrister
  • 2
  • 2
5 Comments
 
LVL 11

Accepted Solution

by:
SThaya earned 1200 total points
ID: 38827073
0
 
LVL 11

Assisted Solution

by:SThaya
SThaya earned 1200 total points
ID: 38827079
0
 

Author Comment

by:lrbrister
ID: 38827211
Maybe I should have been more specific.
I need to marry the
1 header line which is fixed width 6 columns
Many detail lines which is fixed width's 10 columns1 Trailer line which is fixed width 4 columns

So...
In SSIS, can I get the three in sequence, and then append the 3 segments or files together?
0
 
LVL 6

Assisted Solution

by:liija
liija earned 800 total points
ID: 38827940
I think you were specific enough.

If they are fixed, it should be fairly straight forward.
Write data to 'data'file in Data Flow task, then append the files into one with Execute Process task (data + header and footer)
0
 

Author Closing Comment

by:lrbrister
ID: 38828383
Thanks
0

Featured Post

Free learning courses: Active Directory Deep Dive

Get a firm grasp on your IT environment when you learn Active Directory best practices with Veeam! Watch all, or choose any amount, of this three-part webinar series to improve your skills. From the basics to virtualization and backup, we got you covered.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
A Stored Procedure in Microsoft SQL Server is a powerful feature that it can be used to execute the Data Manipulation Language (DML) or Data Definition Language (DDL). Depending on business requirements, a single Stored Procedure can return differe…
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties
Suggested Courses

873 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question