How do you persist objects, permissions in tempdb



How do you persist objects, permissions in tempdb..

Answer / srinivasa ganamur

Hi,

Step 1 : For this you to create new procedure(plcae all
your statments in this procedure), affter creating the
procedure, run this procedure in tempdb.

Step 2 : using sp_procoption (system procedure), you have
to set startup option.means whenever you restart your sql
server the created procedure automatically runs. The Syntax
of sp_procoption is

sp_procoption @proc_name,
@OptionName,
@OptionValue

@ProcName---> Name of the newly created procedure
@OptionName---> StartUP
@OptionValue---> True

Ex: sp_Procoption 'usp_CustomerDetails', 'StartUp', 'True'

Regard's
Srinivasa Ganamur

Is This Answer Correct ?    3 Yes 0 No

Post New Answer

More SQL Server Interview Questions

How to create an index on an existing table in ms sql server?

0 Answers  


how to define testing of network layers? : Sql server database administration

0 Answers  


What are the dis_advantages of stored procedures, triggers, indexes?

0 Answers  


What are the different types of triggers in SQL SERVER?

0 Answers  


What is a result set object returned by mssql_query()?

0 Answers  






What is advantage data architect?

0 Answers  


What is buffer cash and log cache in sql server?

0 Answers  


Is it safe to delete log files?

0 Answers  


What is Replication?

0 Answers  


difference between function and procedure

3 Answers   Cognizant, HCL, TCS, Theorem,


What is sql stored procedure?

0 Answers  


What is open database communication (odbc)?

0 Answers  


Categories