Showing posts with label thejob. Show all posts
Showing posts with label thejob. Show all posts

Friday, March 9, 2012

Next Run Date column not sorting

We've just installed SQL Server 2000 on one of our servers and have
noticed a strange behavior. When clicking the column headings in the
job display in Enterprise Manager, the list is sorted (first click
ascending, then descending) on the column clicked except for "Next Run
Date." When we click on "Next Run Date," the list is reordered, but
randomly. Each time we click it we get a different order but never
ascending or descending. This is true whether we're at the server or
on a remote machine. We never saw this behavior with SQL Server 7.0.

Any ideas? Thanks!"Rich Hurley" <Rich.Hurley@.mci.com> wrote in message
news:e3153db3.0410110535.129c4159@.posting.google.c om...
> We've just installed SQL Server 2000 on one of our servers and have
> noticed a strange behavior. When clicking the column headings in the
> job display in Enterprise Manager, the list is sorted (first click
> ascending, then descending) on the column clicked except for "Next Run
> Date." When we click on "Next Run Date," the list is reordered, but
> randomly. Each time we click it we get a different order but never
> ascending or descending. This is true whether we're at the server or
> on a remote machine. We never saw this behavior with SQL Server 7.0.
> Any ideas? Thanks!

The problem with Enterprise Manager is that you never really know what it's
doing. If you run a SELECT query with an ORDER BY clause in Query Analyzer,
does it return the correct order? QA is a much better and simpler tool for
retreiving and manipulating data than EM, because there's no guesswork
involved and you can control exactly what data you retrieve and how.

Simon|||"Simon Hayes" <sql@.hayes.ch> wrote in message news:<416ad914_2@.news.bluewin.ch>...
> "Rich Hurley" <Rich.Hurley@.mci.com> wrote in message
> news:e3153db3.0410110535.129c4159@.posting.google.c om...
> The problem with Enterprise Manager is that you never really know what it's
> doing. If you run a SELECT query with an ORDER BY clause in Query Analyzer,
> does it return the correct order? QA is a much better and simpler tool for
> retreiving and manipulating data than EM, because there's no guesswork
> involved and you can control exactly what data you retrieve and how.
> Simon

ORDER BY works fine in QA. Ordering also works fine in other columns
of the job list in Ent. Mgr. The "Next Run Date" column is the only
one that is acting weird. If I use SQL 2000 Ent. Mgr. from my laptop
to look at any of our servers (4 SQL 7.0 & 1 SQL 2000) the same
behavior occurs. Ent. Mgr. on our 7.0 servers works fine but, of
course, cannot connect to the 2000 server.

Rich|||"Rich Hurley" <Rich.Hurley@.mci.com> wrote in message
news:e3153db3.0410120501.7ab303bc@.posting.google.c om...
> "Simon Hayes" <sql@.hayes.ch> wrote in message
> news:<416ad914_2@.news.bluewin.ch>...
>> "Rich Hurley" <Rich.Hurley@.mci.com> wrote in message
>> news:e3153db3.0410110535.129c4159@.posting.google.c om...
>>
>> The problem with Enterprise Manager is that you never really know what
>> it's
>> doing. If you run a SELECT query with an ORDER BY clause in Query
>> Analyzer,
>> does it return the correct order? QA is a much better and simpler tool
>> for
>> retreiving and manipulating data than EM, because there's no guesswork
>> involved and you can control exactly what data you retrieve and how.
>>
>> Simon
> ORDER BY works fine in QA. Ordering also works fine in other columns
> of the job list in Ent. Mgr. The "Next Run Date" column is the only
> one that is acting weird. If I use SQL 2000 Ent. Mgr. from my laptop
> to look at any of our servers (4 SQL 7.0 & 1 SQL 2000) the same
> behavior occurs. Ent. Mgr. on our 7.0 servers works fine but, of
> course, cannot connect to the 2000 server.
> Rich

If it's a date column, then perhaps some sort of regional settings issue
might be causing it? Although if it works properly in QA, then I personally
wouldn't worry about it; EM has plenty of other data manipulation issues
anyway, as described in some detail here:

http://www.aspfaq.com/show.asp?id=2455

Simon|||"Simon Hayes" <sql@.hayes.ch> wrote in message news:<416bd8fc$1_3@.news.bluewin.ch>...
> If it's a date column, then perhaps some sort of regional settings issue
> might be causing it? Although if it works properly in QA, then I personally
> wouldn't worry about it; EM has plenty of other data manipulation issues
> anyway, as described in some detail here:
> http://www.aspfaq.com/show.asp?id=2455
> Simon

If the job list was sorted consistently when I click on the column
heading I'd believe it was a regional setting. But everytime I click
the "Next Run Time" heading, I get a random result. The other columns
sort ascending on the first click and descending on a second click and
continue to flip-flop as many times as they are clicked. Not so with
the "Next Run Time" column. There's no rhyme or reason to the order
that jobs are displayed no matter how many times I click -- it's
different each time -- not just a reverse of the previous display.

QA doesn't help when managing jobs -- as the article points out EM is
the preferred tool for that -- QA queries would simply be too long and
too complex. I'm just puzzled by what could cause this weird behavior
in EM.

Thanks,
Rich

next run date

I am setting up a new job that will run weekly. However, after setting up the
job the "NEXT RUN DATE" does not display. If I set up this job on another
server this date does get displayed. What might be the reason for this
behavior?
Can you post the results of the following query here:
SELECT * FROM msdb..sysjobschedules s1
WHERE EXISTS ( SELECT * FROM msdb..sysjobs s2
WHERE s2.job_id = s1.job_id )
AND s2.name = <jobname> );
Replace <jobname> with the name of your job.
Anith
|||Hi,
Below are the results:
schedule_id job_id name
enabled
-- --
37 DE69831F-F6EA-4E71-89B3-6542F82A8D2F test1
freq_typefreq_intervalfreq_subday_typefreq_subday_interval
8 4 1 0
freq_relative_intervalfreq_recurrence_factor
active_start_dateactive_end_date
0 1 2008031099991231
active_start_timeactive_end_timenext_run_datenext_run_time
100000 235959 0 0
date_created
03/10/2008 15:27:27.27
"Anith Sen" wrote:

> Can you post the results of the following query here:
> SELECT * FROM msdb..sysjobschedules s1
> WHERE EXISTS ( SELECT * FROM msdb..sysjobs s2
> WHERE s2.job_id = s1.job_id )
> AND s2.name = <jobname> );
> Replace <jobname> with the name of your job.
> --
> Anith
>
>
|||I see that the next_run_date and next_run_time is not getting inserted into
the sysjobschedules table in msdb database after I create the job. What might
be the reason that this is not getting inserted? This works correctly on
other servers. Is this a permissions issue?
Thanks in advance.
"ronnie" wrote:
[vbcol=seagreen]
> Hi,
> Below are the results:
> schedule_id job_id name
> enabled
> -- --
> --
> 37 DE69831F-F6EA-4E71-89B3-6542F82A8D2F test1
> freq_typefreq_intervalfreq_subday_typefreq_subday_interval
> ----
> 8 4 1 0
> freq_relative_intervalfreq_recurrence_factor
> active_start_dateactive_end_date
> --
> 0 1 2008031099991231
>
> active_start_timeactive_end_timenext_run_datenext_run_time
> ----
> 100000 235959 0 0
>
> date_created
> --
> 03/10/2008 15:27:27.27
>
>
>
>
>
> "Anith Sen" wrote: