Results 1 to 6 of 6
  1. #1
    Join Date
    Mar 2006
    Posts
    11

    Unanswered: Edit User-defined data type in Microsoft SQL server

    Hi,

    I created a user-defined datatype in Microsoft SQL server using the Enterprise Manager. But, I am not able to find options to edit this data type. There are options to delete but not for editing an existing user defined data type.

    Can any one help me how to edit this user defined datatype ?

    Also, are there any better ways to create and manage user defined data types in MS SQL ?


    Thanks in advance ..

    -Sudhakar

  2. #2
    Join Date
    Feb 2004
    Location
    One Flump in One Place
    Posts
    14,912
    Hi

    UDTs are immutable. You will need to ALTER the tables of all the affected columns and change them to a compatible data type, drop your UDT, recreate it with your new definition and ALTER the tables again to return the column data type to your UDT.

    As such - it is wise to employ a fair bit of fore thought when creating UDTs

    HTH
    Testimonial:
    pootle flump
    ur codings are working excelent.

  3. #3
    Join Date
    Jun 2003
    Location
    Ohio
    Posts
    12,592
    Provided Answers: 1
    As such, user-defined datatypes are practically useless.
    If it's not practically useful, then it's practically useless.

    blindman
    www.chess.com: "sqlblindman"
    www.LobsterShot.blogspot.com

  4. #4
    Join Date
    Feb 2004
    Location
    One Flump in One Place
    Posts
    14,912
    They also don't cascade to everything within SQL Server as I recall. I'll be stripped naked and painted blue if I can remember any specifics though....
    Testimonial:
    pootle flump
    ur codings are working excelent.

  5. #5
    Join Date
    Jun 2003
    Location
    Ohio
    Posts
    12,592
    Provided Answers: 1
    They don't cascade to anything. And if you script out your objects, they are scripted as the underlying datatype, not the UDT. Useless.
    If it's not practically useful, then it's practically useless.

    blindman
    www.chess.com: "sqlblindman"
    www.LobsterShot.blogspot.com

  6. #6
    Join Date
    Jul 2009
    Location
    Zimbabwe
    Posts
    1

    Cute Girl

    Coreect

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •