Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2006-07-11 : 11:23:05
|
| Tim writes "Below code runs fine in SQL2000 but not SQL2005. Can someone explain this? Thankscreate table Test2005 (CatID int,ValueID int,ValueText varchar(50) )insert into Test2005 values (1, 1, null)insert into Test2005 values (1, 1, '0.1000')insert into Test2005 values (1, 1, '0.1500')insert into Test2005 values (1, 1, '11')insert into Test2005 values (1, 1, '4')insert into Test2005 values (1, 2, 'Jul 23 2004 12:00AM')insert into Test2005 values (1, 3, 'Jul 24 2004 12:00AM')insert into Test2005 values (1, 4, 'Jul 26 2004 12:00AM')insert into Test2005 values (1, 1, 'N')insert into Test2005 values (1, 1, 'y')Select * from Test2005WHERE 1 = 1AND ValueID in (2,3,4)And CatID in (1)AND ValueText BETWEEN (Convert(Datetime,'5/27/2005') - 365 - 30 ) AND (Convert(Datetime,'5/27/2005') - 120 )" |
|
|
|
|
|
|
|