Results 1 to 5 of 5
  1. #1
    Join Date
    Dec 2009
    Posts
    6

    Unanswered: Unix Textfile To Windows Textfile In SQL Server

    Hi All;

    I receive a UNIX Text File from a client and i need to convert it into a windows text file before i can run a DTS Import job on it.
    Does anyone have any advice or suggestions on how this can be done in SQL Server?

    Thanks for any help.

  2. #2
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    The only difference is likely the end of line treatment: line feed symbol on UNIX versus carriage return/line feed combination on Windows. You can simply specify {LF} as the row delimiter when defining the flat file datasource, no?
    ---
    "It does not work" is not a valid problem statement.

  3. #3
    Join Date
    Feb 2004
    Location
    In front of the computer
    Posts
    15,579
    Provided Answers: 54
    If you really are using DTS, my condolances. Try at least twice to move up to SSIS, SSIS isn't nearly as hard on your sanity as DTS. If you fail to convert from DTS to SSIS both times, you can still do this job using DTS.

    Edit the Source Text File definition within the DTS package, click on Properties button, then click the Advanced Tab. Change the row delimiter from {CR}{LF} to just {LF} and you should be able to run the import smoothly without having to do anything at all to prepare the Unix text file.

    -PatP
    In theory, theory and practice are identical. In practice, theory and practice are unrelated.

  4. #4
    Join Date
    Dec 2009
    Posts
    6
    Thanks to both of you for the input.
    I likely should have looked more in depth to the DTS options.
    Tho likely, from what pat says, i should look right past DTS and at SSIS.
    This will work in the meantime, but does anyone know of any good introductions to SSIS?

  5. #5
    Join Date
    Feb 2004
    Location
    In front of the computer
    Posts
    15,579
    Provided Answers: 54
    I'm biased, but I like Mike Hotek's Amazon.com: Microsoft SQL Server 2008 Step by Step (Step by Step (Microsoft)) (9780735626041): Mike Hotek: Books and Brian Knight's Amazon.com: Knight's 24-Hour Trainer: Microsoft SQL Server 2008 Integration Services (Wrox Programmer to Programmer) (9780470496923): Brian Knight, Devin Knight, Mike Davis: Books for beginning to intermediate SSIS Programmers. They explain what someone new to SSIS needs to know, without "talking down" in the process.

    -PatP
    In theory, theory and practice are identical. In practice, theory and practice are unrelated.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •