Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 

Get your favorite SSC scripts directly in SSMS with the free SQL Scripts addin. Search for scripts directly from SSMS, and instantly access any saved scripts in your SSC briefcase from the favorites tab.
Download now (direct download link)

BCP OUT tables from any database

By SanjayAttray,

This script will help DBA's who wants to BCP out required tables form any database. This script can be run through as a job. Before running you have to create a table in any given database and store the table names in it, which you want to Bulk copy. Query in this procedure will check the table for table names and will copy data in .txt files and store the out put in given path.

(You can change the paths for storing the out put and data text files. Also change the database name. By default I have given pubs..)

Total article views: 248 | Views in the last 30 days: 1
 
Related Articles
FORUM

minimum roles (server/database) should be given to a user to run jobs

minimum roles (server/database) should be given to a user to run jobs

FORUM

stored procedures in a database

stored procedures in a database

FORUM

Synonym-Given String

Sql Server Query -help(Synonym for Given String)

FORUM

"USE DATABASE" in stored procedure workaround?

2 customer databases using the same stored procedure

FORUM

Execute SSIS package stored in Database - From Stored Procedure

Execute SSIS package stored in Database - From Stored Procedure

 
Contribute

Join the most active online SQL Server Community

SQL knowledge, delivered daily, free:

Email address:  

You make SSC a better place

As a member of SQLServerCentral, you get free access to loads of fresh content: thousands of articles and SQL scripts, a library of free eBooks, a weekly database news roundup, a great Q & A platform… And it’s our huge, buzzing community of SQL Server Professionals that makes it such a success.

Join us!

Steve Jones
Editor, SQLServerCentral.com

Already a member? Jump in:

Email address:   Password:   Remember me: Forgotten your password?
Steve Jones