<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=windows-1252">
<META content="MSHTML 6.00.2800.1264" name=GENERATOR>
<STYLE>
<!--
/* Font Definitions */
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
{font-family:"Lucida Sans Unicode";
panose-1:2 11 6 2 3 5 4 2 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman";}
a:link, span.MsoHyperlink
{color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{color:purple;
text-decoration:underline;}
p.MsoAutoSig, li.MsoAutoSig, div.MsoAutoSig
{margin:0in;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman";}
p
{margin-right:0in;
margin-left:0in;
font-size:12.0pt;
font-family:"Times New Roman";}
span.emailstyle17
{font-family:Tahoma;
color:windowtext;
font-weight:normal;
font-style:normal;
text-decoration:none none;}
span.EmailStyle20
{font-family:Tahoma;
color:blue;
font-weight:normal;
font-style:normal;
text-decoration:none none;}
@page Section1
{size:8.5in 11.0in;
margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
{page:Section1;}
-->
</STYLE>
</HEAD>
<BODY lang=EN-US vLink=purple link=blue>
<DIV><SPAN class=094412216-10102003><FONT face="Lucida Sans Unicode"
color=#0000ff size=2>Mark,</FONT></SPAN></DIV>
<DIV><SPAN class=094412216-10102003><FONT face="Lucida Sans Unicode"
color=#0000ff size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=094412216-10102003><FONT face="Lucida Sans Unicode"
color=#0000ff size=2>Unfortunately replication has to be rebuilt. Have SQL
generate the scripts for you so that you can easily recreate those filters.
That's one of the things I hate about the replication scenario. Even a table
structure change will require rebuilding the replication for publications that
reference that table.</FONT></SPAN></DIV>
<DIV><SPAN class=094412216-10102003><FONT face="Lucida Sans Unicode"
color=#0000ff size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=094412216-10102003><FONT face="Lucida Sans Unicode"
color=#0000ff size=2>The ones you need to be concerned about are the ones that
have the spid. </FONT></SPAN></DIV>
<DIV> </DIV>
<P><FONT size=2>---<BR>Eric Barro<BR>Senior Systems Analyst<BR>Advanced Field
Services<BR>(208) 772-7060<BR><A href="http://www.afsweb.com/"
target=_blank>http://www.afsweb.com</A> </FONT></P>
<BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">
<DIV class=OutlookMessageHeader dir=ltr align=left><FONT face=Tahoma
size=2>-----Original Message-----<BR><B>From:</B>
dba-sqlserver-bounces@databaseadvisors.com
[mailto:dba-sqlserver-bounces@databaseadvisors.com]<B>On Behalf Of </B>Mark
Boyd<BR><B>Sent:</B> Friday, October 10, 2003 8:29 AM<BR><B>To:</B>
dba-sqlserver@databaseadvisors.com<BR><B>Subject:</B> RE:
[dba-SQLServer]Repairing a corrupt table<BR><BR></FONT></DIV>
<DIV class=Section1>
<P class=MsoNormal><FONT face=Tahoma color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Tahoma">Eric
–</SPAN></FONT></P>
<P class=MsoNormal><FONT face=Tahoma color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Tahoma">Thanks for your
response.</SPAN></FONT></P>
<P class=MsoNormal><FONT face=Tahoma color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Tahoma">Running sp_who2
returned 15 records with statuses ranging from sleeping, to background, to
runnable.</SPAN></FONT></P>
<P class=MsoNormal><FONT face=Tahoma color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Tahoma">What do these
statuses mean? Should I only be concerned with runnable and
background?</SPAN></FONT></P>
<P class=MsoNormal><FONT face=Tahoma color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Tahoma"></SPAN></FONT> </P>
<P class=MsoNormal><FONT face=Tahoma color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Tahoma">Also, you mention
turning “off” replication.</SPAN></FONT></P>
<P class=MsoNormal><FONT face=Tahoma color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Tahoma">Is there a way to
turn off replication without deleting the subscription? We used many
filters when creating the subscription, and I don’t want to recreate them if I
don’t have to.</SPAN></FONT></P>
<P class=MsoNormal><FONT face=Tahoma color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Tahoma"></SPAN></FONT> </P>
<P class=MsoNormal><FONT face=Tahoma color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Tahoma">Thanks
again,</SPAN></FONT></P>
<P class=MsoNormal><FONT face=Tahoma color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Tahoma">Mark</SPAN></FONT></P>
<P class=MsoNormal><FONT face=Tahoma color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Tahoma"></SPAN></FONT> </P>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face=Tahoma size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">-----Original
Message-----<BR><B><SPAN style="FONT-WEIGHT: bold">From:</SPAN></B> Eric Barro
[mailto:ebarro@afsweb.com] <BR><B><SPAN
style="FONT-WEIGHT: bold">Sent:</SPAN></B> Friday, October 10, 2003 10:53
AM<BR><B><SPAN style="FONT-WEIGHT: bold">To:</SPAN></B>
dba-sqlserver@databaseadvisors.com<BR><B><SPAN
style="FONT-WEIGHT: bold">Subject:</SPAN></B> RE: [dba-SQLServer]Repairing a
corrupt table</SPAN></FONT></P>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"></SPAN></FONT> </P>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Lucida Sans Unicode"
color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Lucida Sans Unicode'">Mark,</SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"></SPAN></FONT> </P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Lucida Sans Unicode"
color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Lucida Sans Unicode'">Go to
the database you want to use and then click on Tools and then SQL Query
Analyzer from the menu.</SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"></SPAN></FONT> </P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Lucida Sans Unicode"
color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Lucida Sans Unicode'">Type
sp_who2 to get a list of connections and processes they are
running.</SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"></SPAN></FONT> </P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Lucida Sans Unicode"
color=blue size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Lucida Sans Unicode'">I
don't believe you can put the db in single user mode with replication turned
on. You will need to turn it off then.</SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"></SPAN></FONT> </P></DIV>
<P style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman" size=2><SPAN
style="FONT-SIZE: 10pt">---<BR>Eric Barro<BR>Senior Systems
Analyst<BR>Advanced Field Services<BR>(208) 772-7060<BR><A
href="http://www.afsweb.com/" target=_blank>http://www.afsweb.com</A>
</SPAN></FONT></P>
<BLOCKQUOTE style="MARGIN-TOP: 5pt; MARGIN-BOTTOM: 5pt; MARGIN-RIGHT: 0in">
<P class=MsoNormal
style="MARGIN-BOTTOM: 12pt; MARGIN-LEFT: 0.5in; MARGIN-RIGHT: 0in"><FONT
face=Tahoma size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">-----Original
Message-----<BR><B><SPAN style="FONT-WEIGHT: bold">From:</SPAN></B>
dba-sqlserver-bounces@databaseadvisors.com
[mailto:dba-sqlserver-bounces@databaseadvisors.com]<B><SPAN
style="FONT-WEIGHT: bold">On Behalf Of </SPAN></B>Mark Boyd<BR><B><SPAN
style="FONT-WEIGHT: bold">Sent:</SPAN></B> Friday, October 10, 2003 6:47
AM<BR><B><SPAN style="FONT-WEIGHT: bold">To:</SPAN></B>
SQLServerList<BR><B><SPAN style="FONT-WEIGHT: bold">Subject:</SPAN></B>
[dba-SQLServer]Repairing a corrupt table</SPAN></FONT></P>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face=Tahoma size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">I am in the process of
repairing a corrupt table.</SPAN></FONT></P>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face=Tahoma size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">My backup software is failing
with the following message: ‘Table Corrupt: Object ID 734690461, Index ID 2.
Keys out of order on page (1:78526), slots 145 and 146.’</SPAN></FONT></P>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face=Tahoma size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">It seems table MSmerge_contents
has become corrupt. This table is used in the replication with another
SQL Server.</SPAN></FONT></P>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face=Tahoma size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">I ran DBCC_CHECKDB to make sure
this was the only table with corruption issues. Now I want to run the
repair option, but am prompted with a message stating the database needs to
be in single-user mode in order to repair. I tried putting the db into
single-user mode, but am prompted with an error message telling me the
option can’t be changed while another user is in the database. I’m
pretty sure no one else is in it, but am thinking the subscription to the
other server needs to be removed to do this.</SPAN></FONT></P>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face=Tahoma size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">Has anyone dealt with this sort
of issue before?</SPAN></FONT></P>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face=Tahoma size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">How can I tell if anyone is
connected to the database?</SPAN></FONT></P>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"></SPAN></FONT> </P>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face=Tahoma size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">TIA,</SPAN></FONT></P>
<P class=MsoAutoSig style="MARGIN-LEFT: 0.5in"><FONT face=Tahoma
size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">Mark
Boyd</SPAN></FONT></P>
<P class=MsoAutoSig style="MARGIN-LEFT: 0.5in"><FONT face=Tahoma
size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">Sr. Systems
Analyst</SPAN></FONT></P>
<P class=MsoAutoSig style="MARGIN-LEFT: 0.5in"><FONT face=Tahoma
size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">McBee Associates,
Inc.</SPAN></FONT></P>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN
style="FONT-SIZE: 12pt"></SPAN></FONT> </P></BLOCKQUOTE></DIV></BLOCKQUOTE></BODY></HTML>