Click here to Skip to main content
15,918,808 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I was reading about Table Value Parameter which seems interesting.. but i want to know that when we define a table type in database where does it get saved? What is its scope? And How can i modify that type .. suppose i created a table type as...

SQL
CREATE TYPE DeptType AS TABLE
(
DeptId INT, DeptName VARCHAR(30)
);



Now how can i get the schema of DeptType in future? How can i modify it?
Posted
Updated 2-Sep-13 19:30pm
v2

1 solution

If you want to See the User Defined Data Types u have to Query the systypes or sys.types table...
SQL
SELECT * FROM sys.types WHERE is_user_defined = 1
SELECT * FROM systypes WHERE xusertype > 256

user Defined Datatypes Cannot be modified... Instead u have to Drop the user defined data type and Create it again...
Check this...
Modifying User Defined Data Types..[^]
dbfriend.net how-to-alter-user-defined-data-type[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900