Hi everybody,
With this select
select Table_Name, Column_Name, Data_Type, Character_Maximum_Length from information_schema.columns where Character_Maximum_Length >=100 order by 1,2
I can get a list of all potentially dangerous fields. Now I want to write a procedure to generate a script to change all of these fields to varchar(100) (not execute it, of course).
How should I proceed in writting such code?
Thanks in advance.
If it's not broken, fix it until it is.
My Blog