How can we import and export using BCP utility?

Answer Posted / kishore

Import to test file:-
--------------------
bcp "SELECT ProcContent FROM <DBName>.dbo.NewProc order by
ID" queryout C:\NewProc.sql -c -S <ServerName> -T

If we can run(dos prompt) above statement in set of records
are store into c:\newproc.sql file.

Export from File:-
-----------------
BULK INSERT myTestCharData FROM 'C:\myTestCharData-c.Dat'
WITH ( DATAFILETYPE='char', FIELDTERMINATOR=',');

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How did you plan your Data ware house project?

1873


Briefly state different between data ware house & data mart?

653


How to generate the cubes in framework manager?

625


What is the difference between dependent data warehouse and independent data warehouse?

691


What are the main steps to build the data warehouse?

741






Explain why denormalization is promoted in universe designing?

620


Explain what are the possible data marts in retail sales?

595


What is the difference between a primary and secondary actor in use case modeling?

691


hi i have 2 users and 4 reports in dashboard.i have to give rights 2 reports for every users. is it possible give the rights in dashboard.if yes plz let me know how is it possible . thanks in advacne for appreciation. bye rohit

1715


What are the steps to build the datawarehouse?

662


Difference between cold fusion 5 and cold fusion mx 6?

683


What should I have in mind when building olap solution from scratch?

621


How to create diff. Types of templates?

642


Explain what are the methodologies of data warehousing?

597


Explain what is the difference between view filter and report filter?

643