i have project many stored procedures, functions, views , tables. i have project deployed within database within same schema. example we'll call "mainproject" now, i've been tasked creating duplicate project in same database . obvious solution clone objects schema. i've been able using sql scripts. have schema called "secondproject" containing objects first schema. the problem is, in of functions, views , procedures, original schema referenced, e.g. declare @somevar int = mainproject.getid(@someobject) , select somecolumn mainproject.sometable , update mainproject.sometable set somecolumn = @somevalue someothercolumn = @someothervalue executing functions ends referencing incorrect schema. going through hundreds of views, procs , functions find , replace occurrences of schema mainproject tedious , potentially unreliable process. my question is, there way specify "within current schema" when referencing object? just doing declar...
Comments
Post a Comment