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 |
toylar
Starting Member
2 Posts |
Posted - 2008-07-16 : 17:46:29
|
Why doesn't sql like my statementSELECT * FROM 2008E-05-1002.dbo.X_PERSONI know that it has to do with my database name...but how do I get it to like it?Error that I'm getting is:Server: Msg 170, Level 15, State 1, Line 1Line 1: Incorrect syntax near '2008E-05'.Thanks |
|
Lamprey
Master Smack Fu Yak Hacker
4614 Posts |
Posted - 2008-07-16 : 17:52:54
|
Try delimiting your database name like: SELECT * FROM [2008E-05-1002].dbo.X_PERSONEDIT: You should search BOL for Identifiers. Specifically, Rules for Regular Identifiers. Your database name breaks the rules for TSQL naming. |
 |
|
toylar
Starting Member
2 Posts |
Posted - 2008-07-16 : 18:08:35
|
duh that worked |
 |
|
|
|
|