Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Replication (2005)
 What is a snapshot?

Author  Topic 

ravilobo
Master Smack Fu Yak Hacker

1184 Posts

Posted - 2007-04-17 : 13:41:09
What is a snapshot from replication point of view.

------------------------
I think, therefore I am - Rene Descartes

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2007-04-17 : 14:01:04
With over 700 posts here, I would expect that you took the time to do a little research in SQL Server Books Online. It is explained in there. Do you want us to copy and paste the information or can you just read about it in BOL?

Tara Kizer
http://weblogs.sqlteam.com/tarad/
Go to Top of Page

ravilobo
Master Smack Fu Yak Hacker

1184 Posts

Posted - 2007-04-17 : 15:50:34
No Tara, you don't need to post it. I know what is a snapshot. But my question has subsquestions which i can ask only after seeing the answer from someone.


------------------------
I think, therefore I am - Rene Descartes
Go to Top of Page

ravilobo
Master Smack Fu Yak Hacker

1184 Posts

Posted - 2007-04-17 : 15:53:13
Any how what I am looking for is - what happens when you run the snapshot second time? Does the subscriber loose the delta changes?

------------------------
I think, therefore I am - Rene Descartes
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2007-04-17 : 16:05:56
Are we talking about snapshot or transactional replication? I ask because my knowledge is on transactional replication.

To see what it will do, check out the properties of the article. The default is drop and create object if it exists. But snapshots only occur on existing objects if you've set the option to reinitialize. Someone correct me if I'm wrong though as I'm just going by what I've seen.

Tara Kizer
http://weblogs.sqlteam.com/tarad/
Go to Top of Page

ravilobo
Master Smack Fu Yak Hacker

1184 Posts

Posted - 2007-04-17 : 16:19:37
I am talking about Merge replication. My understanding is that snapshot is required for all type of replication .

Following is the scenario

1. snapshot runs for the first time
2. subscriber synchronizes
3. subscriber modifies the data
4. snap shot is executed again
5. will the subscriber loses his data ?


------------------------
I think, therefore I am - Rene Descartes
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2007-04-17 : 16:30:49
It depends.

On one system, yes we would lose data as we are replicating to a subscriber from multiple publishers. So if the snapshot runs from one publisher and the article is set to drop/create if object exists, then we would lose all data from the other publishers. We of course would still have the data at the publishers, but we'd would need to get that data across to the subscriber.

On another system, we have modified the schema of the subscriber. Anytime a snapshot occurs, we must first save the data in the columns that we added, run the snapshot, add the columns back in, add the data back in. So we would lose data here too if a snapshot ran and the data wasn't saved first.

You should test on your system to determine what occurs.

Tara Kizer
http://weblogs.sqlteam.com/tarad/
Go to Top of Page
   

- Advertisement -