Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a SQL Server 2005 SP3 box that one of my developers created a temp table on that we cannot seem to remove because it somehow got brackets in the name of the table?

SELECT Name, object_id FROM sys.objects WHERE Name LIKE '%#example%'
Name        object_id
[#example]  123828384 

Anyone know how we can get rid of this? Thanks!

share|improve this question
up vote 1 down vote accepted

THe table wasn't showing up in SMS 2005, so I used SMS 2008 and ran as Administrator, and then I was able to remove the table via the GUI.

share|improve this answer

Just wrap the whole name with square brackets.


drop table [[#example]

Should do it I think

share|improve this answer
That's what I tried first and it just returned a syntax error with "unclosed quotation mark after string" – David George Jun 18 '10 at 19:32

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.