What is the best method to output a text file within a stored procedure? Could you provide examples.
Printable View
What is the best method to output a text file within a stored procedure? Could you provide examples.
Hi Sam,
There are a couple of ways. Assuming you're using MSSQL you could use bcp which can output directly from the stored procedure in a number of different ways. Not the easiest thing to use but workable. Personally I'd return the output to DF and use DF tools to output to my file unless it's absolutely necessary to do it directly from the stored procedure. You can Google bcp if necessary.
Yes, I was thinking that DF may be the way to go if possible.