Stored Procedure Accelerator Guide for Microsoft SQL Server

Stored Procedure Accelerator Guide for Microsoft SQL Server

Creating the Cleanup Procedure Job

Creating the Cleanup Procedure Job

Schedule the cleanup procedure job.
  1. Open the following file in a text editor such as Notepad:
    <Dynamic Data Masking installation>\Accelerators\StoredProcedureMasking\sql\SQLServer\CLEAN_TEMP_OBJECTS_JOB_CREATION_TEMPLATE.sql
  2. Search the text for the following keywords and edit the property values based on the user and client requirements:
    SQLServer_Job_Name
    The name of the job.
    JOB_OWNER_USER_LOGIN_ID
    The database username.
    DDMADMIN_DATABASE
    The Dynamic Data Masking database name.
    DDMADMIN_SCHEMA
    The name of the schema in which you want to run the stored procedure.
    CLEANUP_STORED_PROCEDURE_NAME
    The name of the stored procedure. Enter CLEANUP_TEMP_OBJECTS.
    CLEANUP_SCHEDULE_NAME
    The name of the schedule.
    The following properties are specific to SQL Server job scheduling:
    • @freq_type=< freq_type>
    • @freq_interval=<freq_interval>
    • @freq_subday_type=<freq_subday_type>
    • @freq_subday_interval=<freq_subday_interval>
    • @freq_relative_interval=<freq_relative_interval>
    • @freq_recurrence_factor=<freq_recurrence_factor>
    • @active_start_date=<active_start_date>
    • @active_end_date=<active_end_date>
    • @active_start_time=<active_start_time>
    • @active_end_time=<active_end_time>
    The following text is an example of parameter values that schedule the job to run every minute:
    @freq_type=4, @freq_interval=1, @freq_interval=1, @freq_subday_type=4, @freq_subday_interval=1, @freq_relative_interval=0, @freq_recurrence_factor=0, @active_start_date=20160225, @active_end_date=99991231, @active_start_time=0, @active_end_time=235959,
    For more information about parameter options, refer to the Microsoft documentation at the following URL: https://technet.microsoft.com/en-us/library/aa259582(v=sql.80).aspx
  3. Log in to the database as an administrator.
  4. Run the edited CLEAN_TEMP_OBJECTS_JOB_CREATION_TEMPLATE.sql file to create the job.

0 COMMENTS

We’d like to hear from you!