How to break out files based on size

  • I have a package that I need to split the output text files to 1 meg in size.

    My package has a TsqL container that returns allot of records. I need the txt file output to create as many files as needed but none of them can be over 1 meg.

    No idea how to do that..

  • Do you have to do this in SSIS, or could you create the (big) file as usual and then use some other tool to split the file? Are the files going to be 'reassembled' somewhere, or does the split-point need to be 'clean' (ie, immediately after a row terminator)?


  • Hi Phil.

    I'd prefer to do it all in SSIS, but it's not a requirement.

    Is there a way to do use an external file splitter and call it from SSIS?

  • krypto69 (1/15/2015)


    Hi Phil.

    I'd prefer to do it all in SSIS, but it's not a requirement.

    Is there a way to do use an external file splitter and call it from SSIS?

    My question was not as clear as it could have been. When I said "do it in SSIS", I meant "do it using native SSIS functionality" – I know that you want it to be performed using an SSIS process, one way or the other.

    I haven't had to do it, but if you can find an external splitter which can be called from a command line, it should be fairly trivial to implement in SSIS.


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

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