Hi, I am working on exporting data from SQL Server 2008 R2 database to CSV file format. I want automate this and schedule it as a daily job. I would want to do this in PowerShell and suppress the record count at the very end.
Could please let me know how to write the PowerShell script.
sqlcmd -S localhost -d Test -E -Q "SELECT Id, formatcode, version, submissiondate, agency, coordinator, comments FROM dbo.TestCode" -o "D:\Test\ABCD.csv"Thanks in advance......................
Ione