November 9, 2007 at 1:15 pm
In sql 2005, Adventureworks database, a table name called:
HumanResources.Department has this strange data type on the Name and GroupName columns. Where is (Name(nvarchar(50)) comes from?
What is this (Name...) a function for nvarchar(50)?????
when you try to script the table out, it doesn't even generate the exact datatype for those fields... instead it generated...dbo.Name field.
CREATE TABLE [HumanResources].[Department](
[DepartmentID] [smallint] IDENTITY(1,1) NOT NULL,
[Name] (Name(nvarchar(50)), NOT NULL,
[GroupName] (Name(nvarchar(50)), NOT NULL,
[/b][ModifiedDate] [datetime] NOT NULL
) ON [PRIMARY]
November 9, 2007 at 1:38 pm
check out http://msdn2.microsoft.com/en-us/library/ms124425.aspx
it explains it all.
In this case datatype name is an alias data type.
Johan
Learn to play, play to learn !
Dont drive faster than your guardian angel can fly ...
but keeping both feet on the ground wont get you anywhere :w00t:
- How to post Performance Problems
- How to post data/code to get the best help[/url]
- How to prevent a sore throat after hours of presenting ppt
press F1 for solution, press shift+F1 for urgent solution 😀
Need a bit of Powershell? How about this
Who am I ? Sometimes this is me but most of the time this is me
November 12, 2007 at 1:23 pm
Thank you very much.
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply