Forum Discussion
Sreej320
May 06, 2022Copper Contributor
Data transferring from SQL server table to text file without using bcp
Hi friends, I have data in SQL server table and I need to transfer from it to the text file with specific name format and with column names and specific data size of the data types. I couldnt do ...
mcdasa
May 09, 2022Brass Contributor
Sreej320
you can use sqlcmd tool like olafhelper mentioned above,
or if you're familiar with powershell you can select table datas through powershell and convert datatable to csv.
well, you may need to install sql module, but it's fancy and simple though.
https://docs.microsoft.com/en-us/powershell/module/sqlserver/read-sqltabledata?view=sqlserver-ps
you can use sqlcmd tool like olafhelper mentioned above,
or if you're familiar with powershell you can select table datas through powershell and convert datatable to csv.
well, you may need to install sql module, but it's fancy and simple though.
https://docs.microsoft.com/en-us/powershell/module/sqlserver/read-sqltabledata?view=sqlserver-ps