• Great article, except that you (and the other posters) either don't use Query Analyzer or SSMS to write your queries, or you do and aren't aware of a neat trick...

    In either tool you have a query open where you want the column names of a table to appear. You simply navigate to the table using the tree on the left of the screen. Then expand the + sign next to the table so that you have the usual Columns, Indexes, etc folder headings beneath the table. You can drag and drop the "Columns" folder to your query and PRESTO, the column names appear. MUCH easier 😛

    You can also drag & drop the table name for long names - it will even prefix with dbo. (or other schema if not dbo obviously).

    Since I've been using the drag & drop technique I have always steered clear of the select * but I can understand using the shorthand if you weren't aware of drag/drop.

    Anyhow, good description of the problem. I wonder if you happened to have a string field push over into an integer return column if you might have noticed the problem sooner (because the string wouldn't go into an int column...).