I know this is probably a dumb question but I need to find a for sure answer on this.
When a developer writes SELECT statements in their code will the * clause work with SQL Server 2005
We have tried to discourage such activity but has not worked. We are in the process of moving our systems to SQL Server 2005 and wanted to know if this would be a gotcha.
Thanks for any advice, comments on this subject.
Jeremy

Select Statements in SQL 2005
Maxamor
Is there an article out there that explains what syntax is allowed with T-SQL in 2005
Thanks,
Jeremy
bpsmith
Jeremy:
For one thing, select * leaves "land mines" in stored procedures. What happens is that the meaning of select * is determined at stored procedure compile time and not at stored procedure run time. The problem occurs when a column is added or removed. Since the meaning of SELECT was determined BEFORE the table change occurred there is a disconnect. If columns were added, the SELECT * of the stored procedure doesn't "know" anything about the new columns and does not include them in the results of the compiled SELECT * statement. If columns were deleted from the table the SELECT * statement in the stored procedure now references columns that do not exist.
If someone recompiles the stored procedure without making changes, the stored procedure that was not working correctly might now "mysteriously" begin to work correctly (maybe).
There are other scenarios too, but this should give you the idea of at least one set of problems.
Jeffrey Kent
Thanks for everyones information on this.
Thanks,
Jeremy
Paula M
pravinarote
But, I was wondering if you are refering to "SELECT *" or SELECT using *= and =* for outer joins. The syntax using *= and =* is no longer supported and needs to be removed from all queries.