Checking a columns datatype

Does anyone know if there is a way to check a column's datatype?  I've noticed sometimes if bad data gets uploaded to a datasource it can change the columns type (for example from an int to a string) and I wanted to write a query to catch that faster. Anyone have any ideas?

Tagged:

Best Answer

Answers

  • @Steven, did quinnj's reply help answer your question? 

  • This worked great!  Thanks for the help.  I wanted to avoid coercing the data to a specific data type, because then if there was a problem with the data it would be more difficult for me to find, but I can use this to make a solution.  Thanks a lot!