Nov-19-2022, 08:37 PM
You can do this with python, but what you have above is a Microsoft sqlcmd command for SQL server, and isn't python code.
In python, this can be done using pandas.
see pandas.DataFrame.to_csv
In python, this can be done using pandas.
see pandas.DataFrame.to_csv