Jump to content
xisto Community
Sign in to follow this  
varalu

How Do You Save The Query Results From Ms Sql?

Recommended Posts

I know that it is possible to save the query results from a database to an external file. Though it is not a straight forward process in many of the database, some of them do allow it and others do not. You might have to use an external tool to achieve this functionality.

Say for example you cannot do an export to an external file in Oracle directly. You might have to use some kind of front end software to achive this. I have used TOAD and it has an option to do it... There is an option inbuilt in ORACLE to spool. But what Spool does is save all the queries that are typed, results returned, metadata etc etc. which cannot be used by any other application directly. But in case of TOAD, the results are displayed in a datagrid and user has to export manually and save it in the format required in the specified location. The user will be given a choice of delimiter in the file that is being saved...

Similarly MySQL also has an option... Unlike ORACLE, where it is dependent on external tools like TOAD, MySQL has an inbuilt option which enables exporting the results returned to an external file by specifying the option in the query itself.... This is one of the most convenient ways...

FOr quite some time I was searching for an option to do this in MS SQL. I do not have an installation of this software in my machine and cannot test it... Has anyone got a proven method of doing it in MS SQL? If so... please share it with me. It will be of great help and can help some of my friends who are currently facing this bottleneck. Also, let me know if this can be achieved using some external open source tool, which is again easy to use and does not involves complex process/ procedures.

If you want more help on how it is done exactly in Oracle and MySQL with syntax you can refer to the below link.
http://forums.xisto.com/no_longer_exists/

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.