Solved

sql server 2008, stored procedure

Posted on 2013-10-23
2
264 Views
Last Modified: 2013-11-27
sir i have created one table (degree master) as below in sql server 2008

degreeid  int(identity) PK
degree name varchar(50)

i have few records of data in this table and this table has relationship with two more table (program master and faculty master).

now i want to add a new field to this degree master table after degreeid field.

i.e.
degreeid int(identity)PK
degreetype varchar(50)
degreename varchar(50).

after adding this field when i try to save this table it gives me error and suggest to drop and re-create table again. I also tried it after removing relationship with other two table but still it gives me the same error and suggest me to drop and create table again  which i dont want to do.

Is there any other ways to do so.

thanks
ronak
0
Comment
Question by:ronipats
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 34

Expert Comment

by:Brian Crowe
ID: 39596333
If you are inserting a column, as opposed to just adding it to the end, then you have no choice but to drop and recreate the table.  This is typically handled automatically after a warning prompt from SSMS.  However, there is a default setting that will prevent this action from occurring.  To enable the change...

Go into Tools -> Options -> Designers-> Uncheck "Prevent saving changes that require table re-creation"
0
 
LVL 39

Accepted Solution

by:
Pratima Pharande earned 500 total points
ID: 39596336
0

Featured Post

 Watch the Recording: Learning MySQL 5.7

MySQL 5.7 has a lot of new features. If you've dabbled with an older version of MySQL, it is definitely worth learning.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
What if you have to shut down the entire Citrix infrastructure for hardware maintenance, software upgrades or "the unknown"? I developed this plan for "the unknown" and hope that it helps you as well. This article explains how to properly shut down …
Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.
Viewers will learn how the fundamental information of how to create a table.

627 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question