How do you create a stored procedure to import fix position file

Posted on 2014-08-18
Last Modified: 2016-02-13
How do you create a stored procedure to import a fix position txt file into Microsoft SQL Server?  

I have following fix position data in the  text file

Postition                   Fieldname                           Sample data
1 - 5                           ID                                         12345
6 - 10                         sample1                               ABCD
11 - 12                       sample2                               ZZ
13 - 19                       startdate                              061214

Question by:countyprob
    LVL 32

    Accepted Solution

    Take a look at BULK INSERT.
    LVL 23

    Assisted Solution

    Usually one would do this with an SSIS package and not with a stored procedure.

    Featured Post

    How your wiki can always stay up-to-date

    Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
    - Increase transparency
    - Onboard new hires faster
    - Access from mobile/offline

    Join & Write a Comment

    Slowly Changing Dimension Transformation component in data task flow is very useful for us to manage and control how data changes in SSIS.
    For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
    Using examples as well as descriptions, and references to Books Online, show the different Recovery Models available in SQL Server and explain, as well as show how full, differential and transaction log backups are performed
    Viewers will learn how to use the UPDATE and DELETE statements to change or remove existing data from their tables. Make a table: Update a specific column given a specific row using the UPDATE statement: Remove a set of values using the DELETE s…

    745 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

    Need Help in Real-Time?

    Connect with top rated Experts

    14 Experts available now in Live!

    Get 1:1 Help Now