• I don't see any obvious reason why you couldn't just do this in an SSIS package instead. SSIS can avoid the extra complexity of having to combine your header row with your data rows. You can use any delimiter you want. If you are using XP_CMDShell to do this, you can avoid that just by using SSIS instead. What's the reason behind using just T-SQL to do this?

    Steve (aka sgmunson) 🙂 🙂 🙂
    Rent Servers for Income (picks and shovels strategy)