Export to Fixed width file

  • I have an SSIS process that I would like to replace. It imports an Excel file, transforms the data and exports to a text file. I am trying to create a stored procedure that will do the same so I can execute it from an agent job. All of the solutions I have seen do not seem to be an option for me. SSIS, obviously is not since that is what I am looking to replace. Also, the import/export wizard and BCP do not seem to be options either since I want to automate it. Unless there is a way to execute the BCP utility using t-sql so I can make it part of my stored procedure.

     

    I appreciate any suggestions.

    SG

  • Yes you can execute bcp via TSQL using xp_cmdshell. -- e.g., https://www.sqlservercentral.com/forums/topic/bcp-using-xp_cmdshell

    You can also create Operating System (CmdExec) job steps.

  • Thanks, I probably should have noticed the job steps. I will look into both options.

    Thanks again.

  • This was removed by the editor as SPAM

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply