From: Mahen on 29 Nov 2009 13:31 I am using SQL server 2008 The following command: CREATE TABLE Table1 ( Column1 time(7) ) results in the following message: Msg 2715, Level 16, State 7, Line 1 Column or parameter #1: Cannot find data type time. Please help. Thank you
From: Erland Sommarskog on 29 Nov 2009 13:38 Mahen (mlux(a)eim.ae) writes: > I am using SQL server 2008 > > The following command: > CREATE TABLE Table1 ( Column1 time(7) ) > results in the following message: > Msg 2715, Level 16, State 7, Line 1 > Column or parameter #1: Cannot find data type time. > > Please help. Thank you Run this command: SELECT @@version Or just check the status bar in SQL Server Management Studio. You are obviously not connected to the server you think you are. -- Erland Sommarskog, SQL Server MVP, esquel(a)sommarskog.se Links for SQL Server Books Online: SQL 2008: http://msdn.microsoft.com/en-us/sqlserver/cc514207.aspx SQL 2005: http://msdn.microsoft.com/en-us/sqlserver/bb895970.aspx SQL 2000: http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx
From: Jeffrey Williams on 29 Nov 2009 13:51 Also - check the compatibility level of the database you are in, it could be that the database is 90 and not 100, which would also prevent usage of the new data types. "Erland Sommarskog" <esquel(a)sommarskog.se> wrote in message news:Xns9CD2C7BDFD883Yazorman(a)127.0.0.1... > Mahen (mlux(a)eim.ae) writes: >> I am using SQL server 2008 >> >> The following command: >> CREATE TABLE Table1 ( Column1 time(7) ) >> results in the following message: >> Msg 2715, Level 16, State 7, Line 1 >> Column or parameter #1: Cannot find data type time. >> >> Please help. Thank you > > Run this command: > > SELECT @@version > > Or just check the status bar in SQL Server Management Studio. You > are obviously not connected to the server you think you are. > > > > -- > Erland Sommarskog, SQL Server MVP, esquel(a)sommarskog.se > > Links for SQL Server Books Online: > SQL 2008: http://msdn.microsoft.com/en-us/sqlserver/cc514207.aspx > SQL 2005: http://msdn.microsoft.com/en-us/sqlserver/bb895970.aspx > SQL 2000: > http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx >
From: Phil Brammer on 29 Nov 2009 15:34 "Erland Sommarskog" <esquel(a)sommarskog.se> wrote in message news:Xns9CD2C7BDFD883Yazorman(a)127.0.0.1... > Mahen (mlux(a)eim.ae) writes: >> I am using SQL server 2008 >> >> The following command: >> CREATE TABLE Table1 ( Column1 time(7) ) >> results in the following message: >> Msg 2715, Level 16, State 7, Line 1 >> Column or parameter #1: Cannot find data type time. >> >> Please help. Thank you > > Run this command: > > SELECT @@version > > Or just check the status bar in SQL Server Management Studio. You > are obviously not connected to the server you think you are. Yep, to add to Erland - it could be that 2008 is installed as a named instance, and you are connecting to the default instance (2005) instead of 2008.
From: Erland Sommarskog on 29 Nov 2009 16:47 Jeffrey Williams (jeff.williams3188(a)verizon.net) writes: > Also - check the compatibility level of the database you are in, it > could be that the database is 90 and not 100, which would also prevent > usage of the new data types. Nope, I tested that before I posted. Creating the table on compat level 90 was no problem, nor should it be. Time is just an identifier, it is not a reserved keyword. -- Erland Sommarskog, SQL Server MVP, esquel(a)sommarskog.se Links for SQL Server Books Online: SQL 2008: http://msdn.microsoft.com/en-us/sqlserver/cc514207.aspx SQL 2005: http://msdn.microsoft.com/en-us/sqlserver/bb895970.aspx SQL 2000: http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx
|
Next
|
Last
Pages: 1 2 Prev: using CLR that returns table Next: Insert query using date as where condition |