Click here to Skip to main content
15,901,122 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi guys im passing a data from database to textfile

SELECT * FROM TEST_Table 


How can i save it to a textfile using stored procedure?
Thanks in advance :)
Posted
Comments
Sibasisjena 16-Jan-14 3:30am    
Please look into my solution. If you have any query please ask me.

1 solution

Fetch data from database and loop through the table and one by one write to the text file.

Please go through this link:
How to: Write to a Text File (C# Programming Guide)[^]
 
Share this answer
 
Comments
OriginalGriff 16-Jan-14 3:35am    
Reason for my vote of one: Please read the question.
The OP specifically asked for a solution using a stored procedure which requires SQL code, not C#. The OP does not mention any other language or environment than SQL so a C# solution is entirely inappropriate...
Sibasisjena 16-Jan-14 3:37am    
Thanks for guide me.
OriginalGriff 16-Jan-14 3:46am    
You're welcome!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900