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 |
|
inbs
Aged Yak Warrior
860 Posts |
Posted - 2009-09-30 : 10:46:18
|
i get this error why:Msg 156, Level 15, State 1, Line 4Incorrect syntax near the keyword 'EXCEPT'.SELECT * FROM DB1.dbo.tbl1WHERE DATEPART(m,DateTran)=8EXCEPTSELECT *FROM DB2.dbo.tbl2WHERE DATEPART(m,DateTran)=8 |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2009-09-30 : 10:49:32
|
What is your compatibility level set to? N 56°04'39.26"E 12°55'05.63" |
 |
|
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2009-09-30 : 10:52:42
|
quote: Originally posted by inbs i get this error why:Msg 156, Level 15, State 1, Line 4Incorrect syntax near the keyword 'EXCEPT'.SELECT * FROM DB1.dbo.tbl1WHERE DATEPART(m,DateTran)=8EXCEPTSELECT *FROM DB2.dbo.tbl2WHERE DATEPART(m,DateTran)=8
What is the compatibility level of the database?MadhivananFailing to plan is Planning to fail |
 |
|
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2009-09-30 : 10:53:04
|
MadhivananFailing to plan is Planning to fail |
 |
|
|
inbs
Aged Yak Warrior
860 Posts |
Posted - 2009-09-30 : 11:02:32
|
| DataBase Compatibility level 80 |
 |
|
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2009-09-30 : 11:05:57
|
quote: Originally posted by inbs DataBase Compatibility level 80
You need to change it to 90 byEXEC sp_dbcmptlevel 'your_db',90MadhivananFailing to plan is Planning to fail |
 |
|
|
inbs
Aged Yak Warrior
860 Posts |
Posted - 2009-09-30 : 11:08:06
|
| thanks, i export the data to another server i have sql 2008 on it. |
 |
|
|
|
|
|