how export MSSQL data from a query?


I'm wondering how to export to a simple sql file (like MySQL export) some specific data from my MSSQL 2008 database. I've made a query and I'm just trying to find out a way to export the data from this query. I tried the INTO OUTFILE 'c:\extract.sql' at the end of my query but it doesn't seems to like that...

it's quite urgent, does anyone has an idea?
Kind Regards,
Who is Participating?
Daniel_PLDB Expert/ArchitectCommented:
You can use sql server export data wizard.
You can export to excel, csv file, text files and many other destinations.
Simplest way of doing this is after the query execution completes in the Management Studio, Select all rows (this can be easily done by clicking the top most tab between rows and columns) and right click then select save result as. You can save it to a CSV file simple easy.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.