I would like to e.g. rename my Applicant
table to ApplicantProfile
, as applicant is an abstract entity that has a profile. The profile is not the applicant.
Simply renaming the table is hopelessly inadequate because there are qillions of relationships to Applicant
. My closest solution is scripting the whole DB, and doing a search and replace, but this seems risky, as I have fields like ApplicantId
that mustn't be renamed. I can't do a whole word only, because I have names like `PK_Applicant'.
Is there a known method or tool I can use for this onerous task?
Best Answer
You should be able to generate the appropriate rename scripts using this, and adjust it to whatever naming convention you choose; I've used this to ensure that the names use the current table and column names, so the where clause currently finds names that don't follow that convention.