Microsoft SQL Server 2005
--
Questions
--
Followers
Top Experts
By the Title, I need to Enable the [Alter To] In SQL Server Management Studio 2005.
I need to set Multiline Text as the "Default Value and Binding" on a varchar(Max) field.
I have right clicked and chose [Properties]
And set my logged in user with the [Grant] Permissions and the [Select] Permissions on the
Field that I need to Alter, but to no avail.
Can someone please let me know how to accomplish this feature, as I am setting the updated version of my site Live tomorrow, and this needs to be added in.
Thank You in advance.
Carrzkiss
Zero AI Policy
We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.
Just Issue Alter permissions on that particular table, so that it would be visible.
Are you sure you have the neccesary permissions to alter the table?
(for instance:
-adding a column anywhere other that at the end
-changing (e.g. renaming) a column
)
this usually happens invisibly without your knowledge... unless you go to "Tools->Options->Designers
try doing this and see if management studio blocks you from doing that column change you're trying to do. if it does, then you know your account will need some more advanced permissions as well (like drop and create).
(you might have to use a more advanced login that already has drop &ย create, etc access on that table when you're trying to test the "Prevent saving changes that require table re-creation" option. if you have an SA account or similiar, try using that for the test)






EARN REWARDS FOR ASKING, ANSWERING, AND MORE.
Earn free swag for participating on the platform.
I do not have that option available?
SQL Server 2005 Enterprise.
Where would it be if it is not where it suppose to be?
(Image below)
@QPR
The Table is an older one, made about 3-4 weeks ago, it is not new.
>>neccesary permissions
I thought I did, how do I check for that?
@rrjegan17
>>Just issue ALTER
That is what I did prior to making the post, and it is still greyed out.
Oops...
Got it wrong earlier..
You can't create an ALTER script for a table.
You can ALTER a View, Function, Procedure and other objects but not a Table..
Sorry for the confusion earlier..
but nevertheless, i don't remember being able to modify a column without that "re-creation" restriction blocking me. so i suggest experimenting by adding update, insert, etc access rights until your user gets the change without error. i can't think of anything other than that re-creation blocking you. not sure, but your user login might even need to have an advanced role. (like dbadmin - however that's be the most extreme case) only testing would tell.
(we're using sql 2000 and sql 2005 databases, i just like the sql 2008 management studio interface more due to the intellisense i get when writing queries on my test db's - sql server 2008 express is free and sufficient when only used as a query editor like i use it)

Get a FREE t-shirt when you ask your first question.
We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.
Default Value and Binding.
By doing an Alter.
What I need to do is to add in a Default value that is a Message
To all new members on the site.
How can I add in this information into that Table.FieldName ???
Thanks
Carrzkiss
r-click on table -> edit
then i selected my column and filled in "This is a default note value" in the "Default Value or Binding" field of the column's properties (see screenshot). doing it with sql code as you mentioned now will also work yes :)
now when i add a new row (for example via r-click, "open table"), i leave the "Note" column's value as null - when i go to the new row (thus committing/saving the current row), the null changes to "This is a default note value"
so to do the above i reckon you'll need:
-alter
-insert
-select
-update (cause you'll probably want to update the existing rows with an update query to insert the new default value where they're already null - adding the default value now won't update the existing null values)
as far as i know if you add your user to the "db_ddladmin" database role, you should be able to do the above. your user's requirement to edit the table implies that it's needed as a kind of administrative user on that db.
I already know about setting the default value that way.
BUT if your are going to do multi-lines then that method does not work.
You have to do what I mentioned above (or) through the r-click.
I have all my Default Values already set and am ready to roll now.
Thanks again for your assistance.
All is good now, just would like to find out about doing it through the r-click instead of manually.
All though I have the code now and it all seems to be good and well.
Have a good one.
Carrzkiss






EARN REWARDS FOR ASKING, ANSWERING, AND MORE.
Earn free swag for participating on the platform.
"BUT if your are going to do multi-lines then that method does not work."
not sure what you mean here - i can do a mass insert and the default value will still get assigned.
>>"BUT if your are going to do multi-lines then that method does not work."
I am doing Multi-line, actually, it is more like a double paragraph that I needed as the default value.
(Instructions on how to use the site, that the user can [Delete] after learning)
>>not sure what you mean here - i can do a mass insert and the default value will still get assigned.
Not sure what you are talking about here myself?
I did not say anything about going "a mass insert and default value will still get assigned"???
Please explain
you got a point with the multiline thing. i would've resorted to using a script inserting/updating of the constraint also. (cause its not like you can specify it to put in a "char(13)+char(10)" - or at least not what i'm aware of). the value field for that default value in the gui takes text straight as you enter it, not in a formula kind of way.(as far as i know) :\

Get a FREE t-shirt when you ask your first question.
We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.
Microsoft SQL Server 2005
--
Questions
--
Followers
Top Experts
Microsoft SQL Server 2005 is a suite of relational database management system (RDBMS) products providing multi-user database access functionality.Component services include integration (SSIS), reporting (SSRS), analysis (SSAS), data quality, master data, T-SQL and performance tuning. It includes support for managing XML data and allows a database server to be exposed over web services using Tabular Data Stream (TDS) packets encapsulated within SOAP (protocol) requests.