I have database on dev and live server with the same name and already sync. Now, i have updated some design, import some data and delete extra data.
I would like to sync the dev and live server, how?
Thanks
Microsoft SQL Server 2005
Last Comment
David Todd
8/22/2022 - Mon
David Todd
Hi,
How important is the dev server data?
Standard practice in my shop is to update test overnight by restoring productions latest backup. Dev is updated once a fortnight.
All changes are scripted, and scripts are applied to production by DBA.
Cheers
David
rajneesh1978
ASKER
Dev server data is important because this is the first time launch of programme. I have already restored the dev database one time to production for testing, now i have the updated database in dev instead of live.
Note : Previously i have restored by using Database ->Task-> Bakup and file name is .bak file that i restored in live. Can i follow the same step for updating live again.
We don't have any DBA, so i need to restore the dev database.
But I suggest that in the absence of a DBA, you need to do this like a DBA and script it, because the script is reusable.
use tempdb
go
restore filelistonly from disk = 'Your full path and name of backup file'
;
restore database YourDatabaseName
from disk = 'Your full path and name of backup file'
with
replace
, move 'LogicalDatafile' to 'PhysicalDatafile - including full path'
, move 'LogicalLogfile' to 'PhysicalLogfile - including full path'
, stats = 5
How important is the dev server data?
Standard practice in my shop is to update test overnight by restoring productions latest backup. Dev is updated once a fortnight.
All changes are scripted, and scripts are applied to production by DBA.
Cheers
David