1 2 3 /*
4 ** This procedure creates syscoordinations system table. It must be
5 ** executed from sybsystemdb database only. If executed from any other
6 ** database, the create will return with an appropriate message.
7 **
8 ** This stored procedure must not be modified, unless the changes are
9 ** reflected in syscoordinations manager and upgrade.
10 */11 12 /*
13 ** Messages for "sp_create_syscoordinations"
14 **
15 ** 17260, "Can't run %1! from within a transaction."
16 */17 18 createproceduresp_create_syscoordinationsas19 begin20 21 if @@trancount > 0
22 begin23 /* 17260, "Can't run %1! from within a transaction." */24 raiserror 17260, "sp_create_syscoordinations"
25 return(1)26 end27 28 /* If user does not has the sa role, we cannot continue any further */29 if(proc_role("sa_role")= 0)30 return(1)31 32 dbcc astc("crtcoord")33 34 if(@@error != 0)35 return(1)36 else37 return(0)38 39 end40
exec sp_procxmode 'sp_create_syscoordinations', 'AnyMode'
go
Grant Execute on sp_create_syscoordinations to public
go