Monday, November 23, 2009

SQL2008 Intellisense Quick Fix

I opened a query window under SQL2008 Management studio. Typing "Select * from " , presses ctrl+space bar to bring up the table intellisense. It's not displaying the table in the list (although I have ran the use command on a database).

What have I done?
  1. use AdventureWorks; // this connect my query window the database I wish to use.
  2. Type select * from + [Ctrl+ space bar]. My table that resides in the AdventureWorks db doesn't exist in the drop-down list (as shown below, the list doesn't show tblApplication).


What are the work-arounds?

1. Use full schema in select definition:
Type select * from AdventureWorks.dbo.tblApplication

2.Work-around I found by accident.
Leave the use command on the first line. Type select * from" and ctrl+space. It shows tblApplication in the intellisense result.





No comments: