Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>there is a procedure called sp_get_schedule_description that will return the schedule on a readable format. All the procedure's parameters can be found on the sysschedules table</p> <p>So, for example, I created a Schedule called "My Schedule1" that has the following information:</p> <pre><code>Recuring Weekly Every 2 weeks On tuesday Overy 12 hours Starting at 3 AM enging at 9 PM from 1/3/2012 </code></pre> <p>if I run</p> <pre><code>select freq_type, freq_interval, freq_subday_type, freq_subday_interval, freq_relative_interval, freq_recurrence_factor, active_start_date, active_end_date, active_start_time, active_end_time from sysschedules where name='My Schedule1' </code></pre> <p>that will give me</p> <pre><code>freq_type 8 freq_interval 5 freq_subday_type 8 freq_subday_interval 12 freq_relative_interval 0 freq_recurrence_factor 2 active_start_date 20120301 active_end_date 99991231 active_start_time 30000 active_end_time 210000 </code></pre> <p>if I put these values into sp_get_schedule_description like this:</p> <pre><code>declare @schedule_description NVARCHAR(255) exec sp_get_schedule_description 8, 5, 8, 12, 0, 2, 20120301, 99991231, 30000, 210000, @schedule_description output select @schedule_description </code></pre> <p>Ill get the schedule on a readable format:</p> <pre><code>Every 2 week(s) on Sunday, Tuesday every 12 hour(s) between 30000 and 210000 </code></pre> <p>problem is that it take one schedule at a time, so you would need to come up with some sort of loop to call it once per job putting the description in a temp table ofr example and the you query the temp table with your parameters like on 1: </p> <pre><code>select * from your_table where description like '%Tuesday%' </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload