2

Have three related tables that I would like to bcp export to file(s). This three tables have relationships to each other. Is there a good way to bcp export these tables in a transactionally consistent manner?

1 Answer 1

5

how about creating a database snapshot and then running the BCP against that ?

https://learn.microsoft.com/en-us/sql/relational-databases/databases/create-a-database-snapshot-transact-sql?view=sql-server-ver15

2
  • How do you instruct bcp to connect to the snapshot? Commented Mar 30, 2021 at 22:23
  • 1
    A database snapshot has its own database name. Commented Mar 30, 2021 at 22:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.