SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 Trouble modifying a table
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

weeder
Starting Member

3 Posts

Posted - 03/13/2007 :  08:52:14  Show Profile  Reply with Quote
Hi There,

I am trying to add a new field to a table using enterprise manager by right clicking on the table, choosing design table and adding the new field/column. But when I choose save changes, I receive an error message:

------------------------------------------------------------
Errors were encountered during the save process. Some of the database objects were not saved.
'Comments' Table
-Unable to modify table
ODBC error: [Microsoft][ODBC SQL Server Driver][SQL SERVER] ...
... Cannot drop the table 'dbo.Comments' because it is being used for replication
-----------------------------------------------------------

If it helps I am trying to add a binary (bit) field and a text field of 50 characters. I think the replication it refers to is a merge replication (not sure though is there a way i can find out in EM?)

I have read some articles which refer to this problem and suggest using stored procedures but I really dont know how to do that, having never used them before. I need an idiots guide please!

Let me know if I need to provide more info. Thanks.

harsh_athalye
Flowing Fount of Yak Knowledge

India
5518 Posts

Posted - 03/13/2007 :  08:59:41  Show Profile  Visit harsh_athalye's Homepage  Click to see harsh_athalye's MSN Messenger address  Send harsh_athalye a Yahoo! Message  Reply with Quote
Try adding column using ALTER TABLE statement.

Alter Table Tablename
Add columnname datatype NULL|NOT NULL


Harsh Athalye
India.
"The IMPOSSIBLE is often UNTRIED"
Go to Top of Page

weeder
Starting Member

3 Posts

Posted - 03/13/2007 :  10:06:05  Show Profile  Reply with Quote
I have tried that with a similar error message.
Go to Top of Page

weeder
Starting Member

3 Posts

Posted - 03/13/2007 :  10:21:27  Show Profile  Reply with Quote
http://www.sqlservercentral.com/columnists/pibison/alteringacolumnonareplicatedtable.asp

I think option b on this page may be what I am looking for but how do I go about using this method - unfortunately this artcle assumes the reader has basic sql server knowledge!
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.05 seconds. Powered By: Snitz Forums 2000