简体   繁体   English

SQL数据库备份和用户标识还原

[英]SQL database backup and restore on user id

I have a database which contains details about user information.The database contains 20 tables with users specific details.Every table contains user foreign key. 我有一个数据库,其中包含有关用户信息的详细信息。该数据库包含20个具有用户特定详细信息的表。每个表均包含用户外键。 I want to be able to backup specific user data from the database and restore the backup. 我希望能够从数据库中备份特定的用户数据并还原备份。 Is it possible to restore the backup on a different database that has same tables. 是否可以在具有相同表的其他数据库上还原备份。 I am working on this but not able to find a documentation or article on this. 我正在研究此问题,但无法找到有关此问题的文档或文章。 If you could help me on this if doing this is possible. 如果可以的话,请您帮我。 Thank you in advance 先感谢您

You need to write some SQL to export the data. 您需要编写一些SQL来导出数据。 You can use a number of techniques for example: Gather data using views, stored procedures or a combination of both. 例如,您可以使用多种技术:使用视图,存储过程或两者的组合来收集数据。 Export data using linked servers, import export or SSIS. 使用链接的服务器导出数据,导入导出或SSIS。

There is no backup and restore functionality for a subset if data. 对于数据子集,没有备份和还原功能。

(ps This is for SQL Server. You have three different database engines in your tags.) (ps是针对SQL Server的。标记中有三个不同的数据库引擎。)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM