I found this useful query to rename all my tables, indexes and constrains but I just figured out it didn't rename the columns.
SELECT 'exec sp_rename ' + '''' + NAME + '''' + ', ' + '''' + replace(NAME, 'Tb', 'Tabela') + ''''
FROM sysObjects
WHERE
NAME LIKE 'Tb%'
I know there's syscolumns but I'm not sure how to use in this case.
Question: How can I get the same result of this query but for columns instead of tables?
I appreciate your help in this. I'm using SQL Server 2012. Thanks.