Reputation: 5090
I would be adding a nullable column to an existing table. What are the possible impacts and how to avoid it?
I intend to look out for SELECT *. What else should I be cautious about?
Upvotes: 1
Views: 461
Reputation: 13367
Joins that may already have the same column name coming back as part of the query could become an issue.
For example, let's suppose we have a table 'Client' with a column 'ZipCode', and a table called 'Contractor', that you add 'ZipCode' to. Specifically, if the query has been written to join in both tables "order by ZipCode", ZipCode is ambiguous. Your query will now fail. "order by Client.ZipCode" would have prevented the problem.
Upvotes: 1
Reputation: 6584
Depending on the position of the column also, if you are doing:
INSERT INTO <table> SELECT *
then you may be inserting data into the wrong column.
Upvotes: 1