Showing posts with label row. Show all posts
Showing posts with label row. Show all posts

Wednesday, March 28, 2012

Merge replication with MSSQL/SQLCE using row filters

Hello everyone,
I'm new in replication, I have some - maybe trivial - question.
First of all, I'm using a MSSQL server as a publisher, the clients are
Pocket PC's, running SQLCE. All clients need only a subset of data, which
can be controlled via row filters, using SUSER_SNAME(). For the first
replication, it seems everything is correct, but.
I have 2 tables in the publication with a reference, eg. table X with
fields code,data and table Y with fields xcode,username. The row filters
looks like:
for table X: 'WHERE X.code IN (SELECT Y.xcode FROM Y WHERE Y.xcode=X.code
AND Y.username=SUSER_SNAME())'
for table Y: 'WHERE Y.username=SUSER_SNAME()'
If I add a row to table Y, the referrenced row from table X will not be
transferred through the next merge replication process, causing referential
integrity error. If I reinitialize the publication, it works again. It
seems, the expressions in the row filters has no effect after the first run
of the Snapshot Agent. I've tried JOIN FILTERS, the effect was that the join
filters worked _only_, not the row filters.
Any idea? The dynamic filters option is on. Am I need to create a dynamic
snapshot job for every single client? There are lot's of them .
Thanks for any help,
Nomad
Correct me if I am wrong, but I don't think that you can use SUSER_Sname()
on your pocket PC.
When I issue this command on isqlw on my pocket pc I get an: At least one
input table is required.
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
"Nomad" <gfoyle@.freemail.hu> wrote in message
news:OGlIubKnEHA.3708@.TK2MSFTNGP10.phx.gbl...
> Hello everyone,
> I'm new in replication, I have some - maybe trivial - question.
> First of all, I'm using a MSSQL server as a publisher, the clients are
> Pocket PC's, running SQLCE. All clients need only a subset of data, which
> can be controlled via row filters, using SUSER_SNAME(). For the first
> replication, it seems everything is correct, but.
> I have 2 tables in the publication with a reference, eg. table X with
> fields code,data and table Y with fields xcode,username. The row filters
> looks like:
> for table X: 'WHERE X.code IN (SELECT Y.xcode FROM Y WHERE Y.xcode=X.code
> AND Y.username=SUSER_SNAME())'
> for table Y: 'WHERE Y.username=SUSER_SNAME()'
> If I add a row to table Y, the referrenced row from table X will not be
> transferred through the next merge replication process, causing
referential
> integrity error. If I reinitialize the publication, it works again. It
> seems, the expressions in the row filters has no effect after the first
run
> of the Snapshot Agent. I've tried JOIN FILTERS, the effect was that the
join
> filters worked _only_, not the row filters.
> Any idea? The dynamic filters option is on. Am I need to create a dynamic
> snapshot job for every single client? There are lot's of them .
> Thanks for any help,
> Nomad
>
|||I'm using the SUSER_SNAME function at the publication row/join filters, in a
publisher database. The publisher is a PC running MSSQL, the clients are
Pocket PC's using SQLCE. It seems, the function itself working correctly,
for the first time, I've found not the solution, but the description of this
problem, here:
http://support.microsoft.com/default...n-us%3Bq324362
So this is not a bug, it's a feature .
"Hilary Cotter" <hilary.cotter@.gmail.com> az albbiakat rta a kvetkezo
zenetben news:O4l1BwLnEHA.648@.tk2msftngp13.phx.gbl...[vbcol=seagreen]
> Correct me if I am wrong, but I don't think that you can use SUSER_Sname()
> on your pocket PC.
> When I issue this command on isqlw on my pocket pc I get an: At least one
> input table is required.
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
>
> "Nomad" <gfoyle@.freemail.hu> wrote in message
> news:OGlIubKnEHA.3708@.TK2MSFTNGP10.phx.gbl...
which[vbcol=seagreen]
Y.xcode=X.code[vbcol=seagreen]
> referential
> run
> join
dynamic
>
|||As the artice down below says, this kind of replication process (e.g. using
subqueries referencing other tables in a row filter) could not be executed
using row filters, because row filters won't be evaluated after the first
run of the snaphot agent. This was disappointing .
Now I have a question about JOIN FILTER-s. The behavoiur of the join filters
"cumulative" (or "transitive")? For example, I have a row filter for one
table, and a join filter for another - joined to the first table. So, I will
have only the joined rows from the second table after replication. Am I
right? Can I use row and join filters in cooperation?
"Nomad" <gfoyle@.freemail.hu> az albbiakat rta a kvetkezo zenetben
news:%23dAuB6LnEHA.2612@.TK2MSFTNGP15.phx.gbl...
> I'm using the SUSER_SNAME function at the publication row/join filters, in
a
> publisher database. The publisher is a PC running MSSQL, the clients are
> Pocket PC's using SQLCE. It seems, the function itself working correctly,
> for the first time, I've found not the solution, but the description of
this
> problem, here:
> http://support.microsoft.com/default...n-us%3Bq324362
> So this is not a bug, it's a feature .
|||Yes subset filters and join filters are intended to be used together. Yes
you will only get rows in the join filter table that meet the subset filter
in the parent table.
Philip Vaughn
Program Manager -SQL Server Replication
This posting is provided "as is" with no warranties and confers no rights.
Please reply to newsgroups only, many thanks!
"Nomad" <gfoyle@.freemail.hu> wrote in message
news:OA7wcVnnEHA.4084@.TK2MSFTNGP10.phx.gbl...
> As the artice down below says, this kind of replication process (e.g.
> using
> subqueries referencing other tables in a row filter) could not be executed
> using row filters, because row filters won't be evaluated after the first
> run of the snaphot agent. This was disappointing .
> Now I have a question about JOIN FILTER-s. The behavoiur of the join
> filters
> "cumulative" (or "transitive")? For example, I have a row filter for one
> table, and a join filter for another - joined to the first table. So, I
> will
> have only the joined rows from the second table after replication. Am I
> right? Can I use row and join filters in cooperation?
> "Nomad" <gfoyle@.freemail.hu> az albbiakat rta a kvetkezo zenetben
> news:%23dAuB6LnEHA.2612@.TK2MSFTNGP15.phx.gbl...
> a
> this
>

Merge Replication with Limiting Data in Subscriber

I am using merge replication with row filtering to limit replication of a
table for the past 10 days of data. The problem is that I want the
subscribers to automatically remove the data that is older than 10 days
after the replication is done (assume that the table has a date field).
Question 1:
Using row filters if I make a change on the subscribers (in the event that
it is disconnected for more that 10 days), will the data that is outside of
the 10 days be send back to the main server (the subscriber is updated even
when disconnected).
Question 2:
How can I get the subscribers to delete the data outside of the 10 days ONLY
after replication is completed successfully.
Thanks
1) The filter is evaluated using todays day. So if your filter looks like
this where DateEntered >=Getdate()-10 and your subscriber is offline for 13
days, the filter will evaluate use todays date, and not the date the data
was entered in the subscriber.
2) AFAIK You can't use merge replication for this. I'd consider
bi-directional transactional replication as you can use custom stored
procedures to build this functionality.
"Darion Mapp" <godd@.caribsurf.com> wrote in message
news:#wwkoN1EEHA.2212@.TK2MSFTNGP09.phx.gbl...
> I am using merge replication with row filtering to limit replication of a
> table for the past 10 days of data. The problem is that I want the
> subscribers to automatically remove the data that is older than 10 days
> after the replication is done (assume that the table has a date field).
> Question 1:
> Using row filters if I make a change on the subscribers (in the event that
> it is disconnected for more that 10 days), will the data that is outside
of
> the 10 days be send back to the main server (the subscriber is updated
even
> when disconnected).
> Question 2:
> How can I get the subscribers to delete the data outside of the 10 days
ONLY
> after replication is completed successfully.
> Thanks
>
|||Darion,
perhaps you could cheat a little here. If you update the old rows on the
subscriber, then synchronize, replication (the merge agent) should remove
them for you. So, you could do an update to the same value on another
column -
update table set col1=col1 where datediff(dd,dateentered, getdate()) > 10.
This won't effectively change the publisher and will be replicated back to
the subscriber as a delete because it doesn't satisfy the filter clause
(view).
Regards,
Paul Ibison
|||Let me fully explain. The table under question is appended to daily. each
row that is added is date stamped. the subscriber is on a laptop. so when
the laptop is off the network there are rows added to its copy of the table
and i want to know if the laptop is reconnected to the network about 15 days
after will all 15 days of data get back to the main server or not? given
that the replication of the table is setup with a row filter that limits its
replication to 10 days worth of data from the main server to the laptop.
"Darion Mapp" <godd@.caribsurf.com> wrote in message
news:%23wwkoN1EEHA.2212@.TK2MSFTNGP09.phx.gbl...
> I am using merge replication with row filtering to limit replication of a
> table for the past 10 days of data. The problem is that I want the
> subscribers to automatically remove the data that is older than 10 days
> after the replication is done (assume that the table has a date field).
> Question 1:
> Using row filters if I make a change on the subscribers (in the event that
> it is disconnected for more that 10 days), will the data that is outside
of
> the 10 days be send back to the main server (the subscriber is updated
even
> when disconnected).
> Question 2:
> How can I get the subscribers to delete the data outside of the 10 days
ONLY
> after replication is completed successfully.
> Thanks
>
|||Darion,
the 15 days of data will go to the publisher. The first 5 days of data
(oldest 5 days) will be replicated back as deletes to the subscriber but
will remain on the publisher. Is that the behaviour you want?
Regards,
Paul Ibison
|||That is EXACTLY what i wanted to know.
Thanks Paul
"Paul Ibison" <Paul.Ibison@.Pygmalion.Com> wrote in message
news:etGkHP2EEHA.2460@.TK2MSFTNGP10.phx.gbl...
> Darion,
> the 15 days of data will go to the publisher. The first 5 days of data
> (oldest 5 days) will be replicated back as deletes to the subscriber but
> will remain on the publisher. Is that the behaviour you want?
> Regards,
> Paul Ibison
>

Friday, March 23, 2012

merge replication script problem

Hi all:
i set up merge replication with row and column filter in sql 2000 and
it works fine, so i generate the script and try to run this script in
another computer, i alway got errors like "table name does not exist etc",
those tables definately exist in DB.
i worked it out after i delete all column fiters in script, does any
one know what's the problem?
Cheers
nick
could you post your table schema and your publication script?
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"Nick" <fsheng@.ebreathe.co.nz> wrote in message
news:euoHn5JCFHA.936@.TK2MSFTNGP12.phx.gbl...
> Hi all:
> i set up merge replication with row and column filter in sql 2000
and
> it works fine, so i generate the script and try to run this script in
> another computer, i alway got errors like "table name does not exist etc",
> those tables definately exist in DB.
> i worked it out after i delete all column fiters in script, does any
> one know what's the problem?
>
> Cheers
> nick
>

Merge replication row size question...

I took the following from BOL...
Replication->Planning for Replication->Evaluating the Replication Env->
Planning for Application Development
"A table used in a merge publication can have a maximum of 246 columns and a
maximum row size of 6,000 bytes"
Is this true? Whats the actual impact on the system when a row size exceeds
6,000 bytes? I have a merge replication setup that has text and image columns
that well exceed the limit stated above, but I have not encountered any
issues. Are the sizes of text and image data columns counted in Microsofts
reference to "maximum row size" -or- do they just count the size of a pointer
in a text column (16 bytes)?
Does this only become a problem when databases are large? My test db is
about 800MB.
I calculated the row size in my db by running select data_length(column_a)
from table_a
Thanks,
Alex C.
my experieince is that only the first 6000 bytes will be logged to the
conflict tables. Note than you can replicate more than 6k using merge, but
if you have any conflict the conflict tables will only record the first 6k
bytes of the conflict.
"acastner" <acastner@.discussions.microsoft.com> wrote in message
news:E5D069BB-74E4-471C-A342-14542F8C8FAE@.microsoft.com...
> I took the following from BOL...
> Replication->Planning for Replication->Evaluating the Replication Env->
> Planning for Application Development
> "A table used in a merge publication can have a maximum of 246 columns and
a
> maximum row size of 6,000 bytes"
> Is this true? Whats the actual impact on the system when a row size
exceeds
> 6,000 bytes? I have a merge replication setup that has text and image
columns
> that well exceed the limit stated above, but I have not encountered any
> issues. Are the sizes of text and image data columns counted in Microsofts
> reference to "maximum row size" -or- do they just count the size of a
pointer
> in a text column (16 bytes)?
> Does this only become a problem when databases are large? My test db is
> about 800MB.
> I calculated the row size in my db by running select data_length(column_a)
> from table_a
> Thanks,
> Alex C.

Merge replication row filter

I have a situation which I can't seem to find an answer to. I have
merge replication set up in SQL2005 and everything seems to work find
except that the row filter for a table isn't working 100%. I have 200
or so field guys who have SQL Express installed on their laptops who
syncronize data back to the server through web syncronization. The
filter in question looks like this:
SELECT <published columns> FROM [dbo].[Stores]
WHERE Division =
(SELECT DivID FROM Divisions
WHERE DistrictDivision = HOST_NAME())
The row filter works fine except when a store is moved from one
division to the next. While it shows up in the new division, it
remains in the old one. I have tested the select statements used in
the filter and they return act as expected. Has anyone seen anything
like this?
Thanks in advance
JC
Hi,
On SQL2005 there is a parameter to sp_addmergepublication called
@.allow_partition_realignment. It sounds like the option you need if
you want to remove a store from the old division. You may need to
consider realigning your current subscribers by forcing a
reinitialisation.
http://msdn2.microsoft.com/en-us/library/ms176103.aspx
Tim
On Mar 31, 6:07 pm, "JC" <jbzcoo...@.gmail.com> wrote:
> I have a situation which I can't seem to find an answer to. I have
> merge replication set up in SQL2005 and everything seems to work find
> except that the row filter for a table isn't working 100%. I have 200
> or so field guys who have SQL Express installed on their laptops who
> syncronize data back to the server through web syncronization. The
> filter in question looks like this:
> SELECT <published columns> FROM [dbo].[Stores]
> WHERE Division =
> (SELECT DivID FROM Divisions
> WHERE DistrictDivision = HOST_NAME())
> The row filter works fine except when a store is moved from one
> division to the next. While it shows up in the new division, it
> remains in the old one. I have tested the select statements used in
> the filter and they return act as expected. Has anyone seen anything
> like this?
> Thanks in advance
> JC

Monday, March 12, 2012

Merge replication issues

We are getting a conflict error message "cannot synchronize, row was updated
outside of replication".
We cannot figure out what is causing this.
Can having different foreign key constraints at a publisher and subscriber
level cause problems with merge replication?
Sorry for the lack of information, but hopefully someone can help!
I have not seen that error message, but based upon my own limited
experiences, I can assure you that different constraints could certainly
create issues.
"llihp" <phill_dutton@.hotmail.com> wrote in message
news:428cb301_1@.x-privat.org...
> We are getting a conflict error message "cannot synchronize, row was
> updated
> outside of replication".
> We cannot figure out what is causing this.
> Can having different foreign key constraints at a publisher and subscriber
> level cause problems with merge replication?
> Sorry for the lack of information, but hopefully someone can help!
>
|||perhaps the row was updated by a process which did not trigger the triggers,
i.e. bcp, dts.
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"llihp" <phill_dutton@.hotmail.com> wrote in message
news:428cb301_1@.x-privat.org...
> We are getting a conflict error message "cannot synchronize, row was
updated
> outside of replication".
> We cannot figure out what is causing this.
> Can having different foreign key constraints at a publisher and subscriber
> level cause problems with merge replication?
> Sorry for the lack of information, but hopefully someone can help!
>
|||"Hilary Cotter" <hilary.cotter@.gmail.com> wrote in message
news:eYHGHAPXFHA.2348@.TK2MSFTNGP14.phx.gbl...
> perhaps the row was updated by a process which did not trigger the
triggers,
> i.e. bcp, dts.
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
I'm not sure what bcp is(?), but we aren't using any DTS packages within the
application.
Basically we are running a VB application at the sites, and this is
manipulating all the data within the database which is then susposed to be
sent back to the central server. We are having no issues with inserted rows
being replicated, it is only updates which are proving problematic.
|||Hi,
I am also getting the same error. I have multiple publishers with a central
subscriber ( using merge property -exchangetype 2). Please let me know if
there is any answere to it.
One stange thing that I have noticed is following:
I have Publications on Same Articles at 4 sites . Some articles have 4
insert, 4 update and 4 delete triggers but some articles get only 1 trigger
for update, 1 for delete and 1 for insert. Why is this so?
"llihp" wrote:

> "Hilary Cotter" <hilary.cotter@.gmail.com> wrote in message
> news:eYHGHAPXFHA.2348@.TK2MSFTNGP14.phx.gbl...
> triggers,
> I'm not sure what bcp is(?), but we aren't using any DTS packages within the
> application.
> Basically we are running a VB application at the sites, and this is
> manipulating all the data within the database which is then susposed to be
> sent back to the central server. We are having no issues with inserted rows
> being replicated, it is only updates which are proving problematic.
>
>
|||Are all the triggers replication related? There should only be one trigger.
You might need to regenerate and resend your snapshot.
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"Vikas Kohli" <VikasKohli@.discussions.microsoft.com> wrote in message
news:C682F2C2-AFAD-42FC-90C1-F81B1BE12928@.microsoft.com...
> Hi,
> I am also getting the same error. I have multiple publishers with a
central
> subscriber ( using merge property -exchangetype 2). Please let me know if
> there is any answere to it.
> One stange thing that I have noticed is following:
> I have Publications on Same Articles at 4 sites . Some articles have 4
> insert, 4 update and 4 delete triggers but some articles get only 1
trigger[vbcol=seagreen]
> for update, 1 for delete and 1 for insert. Why is this so?
> "llihp" wrote:
the[vbcol=seagreen]
be[vbcol=seagreen]
rows[vbcol=seagreen]

Wednesday, March 7, 2012

Merge Replication Error

I have a table called Table1 at both pulisher and subcriber which is related
to
many other tables. If i modify a row at the subcriber then instead of
updating the row at pulisher..merge agent detects conflict and overwrites th
e
row at the subcriber with the row that publisher has and newly inserted row
at subscriber is added to conflict table with the errortype =9 and text
The row was updated at subcriberX but could not be updated at PublisherX.
Unable to synchronize the row because the row was updated by a different
process outside of replication.
I am using SQL Server 2000 with SP4
ThanksI believe this error is cause by a non-logged operation - like DTS. Did you
DTS some data into one of the tables you are merge replicating?
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"kailux4" <kailux4@.discussions.microsoft.com> wrote in message
news:2C08C5E7-EC46-4110-8027-51AB8EF2C290@.microsoft.com...
>I have a table called Table1 at both pulisher and subcriber which is
>related
> to
> many other tables. If i modify a row at the subcriber then instead of
> updating the row at pulisher..merge agent detects conflict and overwrites
> the
> row at the subcriber with the row that publisher has and newly inserted
> row
> at subscriber is added to conflict table with the errortype =9 and text
> The row was updated at subcriberX but could not be updated at PublisherX.
> Unable to synchronize the row because the row was updated by a different
> process outside of replication.
> I am using SQL Server 2000 with SP4
> Thanks|||Hello Hilary,
I am not using DTS or other non logged operations..but still i get this erro
r
"Hilary Cotter" wrote:

> I believe this error is cause by a non-logged operation - like DTS. Did yo
u
> DTS some data into one of the tables you are merge replicating?
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "kailux4" <kailux4@.discussions.microsoft.com> wrote in message
> news:2C08C5E7-EC46-4110-8027-51AB8EF2C290@.microsoft.com...
>
>

Merge Replication Error

I have a table called Table1 at both pulisher and subcriber which is related
to
many other tables. If i modify a row at the subcriber then instead of
updating the row at pulisher..merge agent detects conflict and overwrites the
row at the subcriber with the row that publisher has and newly inserted row
at subscriber is added to conflict table with the errortype =9 and text
The row was updated at subcriberX but could not be updated at PublisherX.
Unable to synchronize the row because the row was updated by a different
process outside of replication.
I am using SQL Server 2000 with SP4
Thanks
I believe this error is cause by a non-logged operation - like DTS. Did you
DTS some data into one of the tables you are merge replicating?
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"kailux4" <kailux4@.discussions.microsoft.com> wrote in message
news:2C08C5E7-EC46-4110-8027-51AB8EF2C290@.microsoft.com...
>I have a table called Table1 at both pulisher and subcriber which is
>related
> to
> many other tables. If i modify a row at the subcriber then instead of
> updating the row at pulisher..merge agent detects conflict and overwrites
> the
> row at the subcriber with the row that publisher has and newly inserted
> row
> at subscriber is added to conflict table with the errortype =9 and text
> The row was updated at subcriberX but could not be updated at PublisherX.
> Unable to synchronize the row because the row was updated by a different
> process outside of replication.
> I am using SQL Server 2000 with SP4
> Thanks
|||Hello Hilary,
I am not using DTS or other non logged operations..but still i get this error
"Hilary Cotter" wrote:

> I believe this error is cause by a non-logged operation - like DTS. Did you
> DTS some data into one of the tables you are merge replicating?
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "kailux4" <kailux4@.discussions.microsoft.com> wrote in message
> news:2C08C5E7-EC46-4110-8027-51AB8EF2C290@.microsoft.com...
>
>

Merge Replication Error

I have a table called Table1 at both pulisher and subcriber which is related
to
many other tables. If i modify a row at the subcriber then instead of
updating the row at pulisher..merge agent detects conflict and overwrites the
row at the subcriber with the row that publisher has and newly inserted row
at subscriber is added to conflict table with the errortype =9 and text
The row was updated at subcriberX but could not be updated at PublisherX.
Unable to synchronize the row because the row was updated by a different
process outside of replication.
I am using SQL Server 2000 with SP4
ThanksI believe this error is cause by a non-logged operation - like DTS. Did you
DTS some data into one of the tables you are merge replicating?
--
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"kailux4" <kailux4@.discussions.microsoft.com> wrote in message
news:2C08C5E7-EC46-4110-8027-51AB8EF2C290@.microsoft.com...
>I have a table called Table1 at both pulisher and subcriber which is
>related
> to
> many other tables. If i modify a row at the subcriber then instead of
> updating the row at pulisher..merge agent detects conflict and overwrites
> the
> row at the subcriber with the row that publisher has and newly inserted
> row
> at subscriber is added to conflict table with the errortype =9 and text
> The row was updated at subcriberX but could not be updated at PublisherX.
> Unable to synchronize the row because the row was updated by a different
> process outside of replication.
> I am using SQL Server 2000 with SP4
> Thanks|||Hello Hilary,
I am not using DTS or other non logged operations..but still i get this error
"Hilary Cotter" wrote:
> I believe this error is cause by a non-logged operation - like DTS. Did you
> DTS some data into one of the tables you are merge replicating?
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "kailux4" <kailux4@.discussions.microsoft.com> wrote in message
> news:2C08C5E7-EC46-4110-8027-51AB8EF2C290@.microsoft.com...
> >I have a table called Table1 at both pulisher and subcriber which is
> >related
> > to
> > many other tables. If i modify a row at the subcriber then instead of
> > updating the row at pulisher..merge agent detects conflict and overwrites
> > the
> > row at the subcriber with the row that publisher has and newly inserted
> > row
> > at subscriber is added to conflict table with the errortype =9 and text
> >
> > The row was updated at subcriberX but could not be updated at PublisherX.
> > Unable to synchronize the row because the row was updated by a different
> > process outside of replication.
> > I am using SQL Server 2000 with SP4
> >
> > Thanks
>
>

merge replication data validation

After addition of new tables to Merge replication data validation fails
if i use only row count and checksum, however if i use binary checksum
and rowcount it is successful.
Checksum is notoriously unreliable. It looks like your tables are out of
sync. I suggest you reinitialize your subscriptions.
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"mitsql" <amit.nimje@.tcs.com> wrote in message
news:1135762365.429312.266610@.o13g2000cwo.googlegr oups.com...
> After addition of new tables to Merge replication data validation fails
> if i use only row count and checksum, however if i use binary checksum
> and rowcount it is successful.
>
|||I have dropped and recreated the subsrciption. still gives the same
error.
All published tables have been recreated so there should not be any
difference in the tables..rt?
Also did a manual checksum using sp_table_validation for the table on
both
subsrciber and publisher and both return the same checksum..
Fail to understand how checksum fails and binary checksum successful?
Hilary Cotter wrote:[vbcol=seagreen]
> Checksum is notoriously unreliable. It looks like your tables are out of
> sync. I suggest you reinitialize your subscriptions.
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "mitsql" <amit.nimje@.tcs.com> wrote in message
> news:1135762365.429312.266610@.o13g2000cwo.googlegr oups.com...
|||Hi,
Thankyou for the response. I even checked the table manually comparing
the
values row by row and found no difference.
Puzzled by this behaviour...
regds,
amit
|||I take it you have the same collation and there is no filtering involved.
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"mitsql" <amit.nimje@.tcs.com> wrote in message
news:1135910034.397450.123480@.g43g2000cwa.googlegr oups.com...
> Hi,
> Thankyou for the response. I even checked the table manually comparing
> the
> values row by row and found no difference.
> Puzzled by this behaviour...
> regds,
> amit
>
|||Hence the comment that checksum validation wasn't always completely
accurate. I've run into this more than once. I've never been able to track
it down and I've never been able to reliably reproduce it.
That's why I look at the validation as a guideline. I still do random
samples of data and directly compare them externally. (This is a lot easier
than you might think.) I basically execute the same query against the
publisher and subscriber and yank all of the data into two tables. If the
rowcount is odd, I know I have a problem. If a union query yields exactly
1/2 of the total rows between the two tables, they are in synch.
Mike
Mentor
Solid Quality Learning
http://www.solidqualitylearning.com
"Hilary Cotter" <hilary.cotter@.gmail.com> wrote in message
news:u%235eYOgDGHA.2320@.TK2MSFTNGP11.phx.gbl...
>I take it you have the same collation and there is no filtering involved.
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "mitsql" <amit.nimje@.tcs.com> wrote in message
> news:1135910034.397450.123480@.g43g2000cwa.googlegr oups.com...
>
|||thanks for respoding back..
Yes have the same collation and no filtering...
Can you tell me which is better binary checksum or checksum
validation?
And how this problem can be resolved for checksum validation failure?
any tracing ?

Monday, February 20, 2012

Merge Replication and publisher deleting subscriber inserts.

The row was inserted at 'Subscriber Laptop' but could not be inserted at
'Publisher server'. INSERT statement conflicted with COLUMN FOREIGN KEY
constraint 'FK1'. The conflict occurred in database 'Tst', table 'Report',
column 'ReportNo'.
http://support.microsoft.com/default...b;en-us;307356
We are using Merge Replication. Sql Server 2000 SP4 on the server and MSDE
SP4 on the laptops.
We've been testing for a few months and just starting to trickle into
production. This is the first time we've seen this error. From what I could
google, the KB I refer to above says we should have NOT FOR REPLICATION on
all FK constraints.
Now, all of my hits on this subject seem to be 2003 and earlier. So before I
go ahead and make this huge change, I want to confirm that yes, infact, I
should be doing this.
Should NFR be put on Primary Keys as well?
Can this NFR be specified through VISIO as that is where we maintain the
data model. If not, is there an alter statement we can apply to constraints
to turn this option on?
Buzz.
NFR can't be put onto PKs but definitely you should have it on the FKs (see
http://www.replicationanswers.com/Me...derArticle.asp)
Cheers,
Paul Ibison SQL Server MVP, www.replicationanswers.com
(recommended sql server 2000 replication book:
http://www.nwsu.com/0974973602p.html)