• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 325
  • Last Modified:

Column exists in temp table

Is there a way I can test to see if a certain column exists in a temporary table?
0
PsychoDazey
Asked:
PsychoDazey
1 Solution
 
obahatCommented:
SELECT * FROM tempdb..syscolumns where id = object_id('tempdb..#<TempTableName>')
0
 
PsychoDazeyAuthor Commented:
thank you sir!  I should have known to look in TempDB....DOH!
0

Featured Post

Microsoft Certification Exam 74-409

VeeamĀ® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now