Home Microsoft SQL Server DigiMailing iRN Contact
    Keyword



dbo.sysjobs_view

  No additional text.


Syntax
CREATE VIEW sysjobs_view
AS
SELECT jobs.job_id,
       svr.originating_server,
       jobs.name,
       jobs.enabled,
       jobs.description,
       jobs.start_step_id,
       jobs.category_id,
       jobs.owner_sid,
       jobs.notify_level_eventlog,
       jobs.notify_level_email,
       jobs.notify_level_netsend,
       jobs.notify_level_page,
       jobs.notify_email_operator_id,
       jobs.notify_netsend_operator_id,
       jobs.notify_page_operator_id,
       jobs.delete_level,
       jobs.date_created,
       jobs.date_modified,
       jobs.version_number,
       jobs.originating_server_id,
       svr.master_server
FROM msdb.dbo.sysjobs as jobs
  JOIN msdb.dbo.sysoriginatingservers_view as svr
    ON jobs.originating_server_id = svr.originating_server_id
  --LEFT JOIN msdb.dbo.sysjobservers js ON jobs.job_id = js.job_id
WHERE (owner_sid = SUSER_SID())
   OR (ISNULL(IS_SRVROLEMEMBER(N'sysadmin'), 0) = 1)
   OR (ISNULL(IS_MEMBER(N'SQLAgentReaderRole'), 0) = 1)
   OR ( (ISNULL(IS_MEMBER(N'TargetServersRole'), 0) = 1) AND
        (EXISTS(SELECT * FROM msdb.dbo.sysjobservers js
         WHERE js.server_id <> 0 AND js.job_id = jobs.job_id))) -- filter out local jobs

 
Last revision 2008RTM
See also

  sp_adddistributiondb (Procedure)
sp_addmergepullsubscription_agent (Procedure)
sp_addpullsubscription_agent (Procedure)
sp_add_jobserver (Procedure)
sp_changereplicationserverpasswords (Procedure)
sp_check_for_owned_jobsteps (Procedure)
sp_dbmmonitoraddmonitoring (Procedure)
sp_delete_all_msx_jobs (Procedure)
sp_delete_job (Procedure)
sp_delete_jobsteplog (Procedure)
sp_delete_job_references (Procedure)
sp_dropmergepullsubscription (Procedure)
sp_droppullsubscription (Procedure)
sp_droptask (Procedure)
sp_get_composite_job_info (Procedure)
sp_get_job_status_mergepullsubscription_agent (Procedure)
sp_get_job_status_mergepushsubscription_agent (Procedure)
sp_help_alert (Procedure)
sp_help_downloadlist (Procedure)
sp_help_jobactivity (Procedure)
sp_help_jobhistory (Procedure)
sp_help_jobhistory_full (Procedure)
sp_help_jobhistory_sem (Procedure)
sp_help_jobhistory_summary (Procedure)
sp_help_jobsteplog (Procedure)
sp_help_operator_jobs (Procedure)
sp_MSadd_distribution_agent (Procedure)
sp_MSadd_distributor_alerts_and_responses (Procedure)
sp_MSadd_logreader_agent (Procedure)
sp_MSadd_log_shipping_history_detail (Procedure)
sp_MSadd_merge_agent (Procedure)
sp_MSadd_qreader_agent (Procedure)
sp_MSadd_repl_job (Procedure)
sp_MSadd_snapshot_agent (Procedure)
sp_MSchange_distribution_agent_properties (Procedure)
sp_MSchange_merge_agent_properties (Procedure)
sp_MSchange_repl_job_unsafe (Procedure)
sp_MSchange_snapshot_agent_properties (Procedure)
sp_MScheck_snapshot_agent (Procedure)
sp_MScreate_replication_checkup_agent (Procedure)
sp_MSdistpublisher_cleanup (Procedure)
sp_MSdistributionagentjobcontrol (Procedure)
sp_MSdrop_distribution_agent (Procedure)
sp_MSdrop_distributor_alerts_and_responses (Procedure)
sp_MSdrop_dynamic_snapshot_agent (Procedure)
sp_MSdrop_logreader_agent (Procedure)
sp_MSdrop_merge_agent (Procedure)
sp_MSdrop_merge_agentid (Procedure)
sp_MSdrop_qreader_agent (Procedure)
sp_MSdrop_repl_job_unsafe (Procedure)
sp_MSdrop_snapshot_agent (Procedure)
sp_MShelp_publication (Procedure)
sp_MShelp_snapshot_agentid (Procedure)
sp_MSisdistributionjobnamegenerated (Procedure)
sp_MSislogreaderjobnamegenerated (Procedure)
sp_MSismergejobnamegenerated (Procedure)
sp_MSispulldistributionjobnamegenerated (Procedure)
sp_MSispullmergejobnamegenerated (Procedure)
sp_MSisqueuereaderjobnamegenerated (Procedure)
sp_MSissnapshotjobnamegenerated (Procedure)
sp_MSmergeagentjobcontrol (Procedure)
sp_MSmergepullsubscriptionagentjobcontrol (Procedure)
sp_MSprocesslogshippingjob (Procedure)
sp_MSpullsubscriptionagentjobcontrol (Procedure)
sp_MSremovedbreplication (Procedure)
sp_MSreplagentjobexists (Procedure)
sp_MSrepl_add_expired_sub_cleanup_job (Procedure)
sp_MSrepl_drop_expired_sub_cleanup_job (Procedure)
sp_MSsnapshotagentjobcontrol (Procedure)
sp_MSupgrade_distdb_security_metadata (Procedure)
sp_MSupgrade_subdb_security_metadata (Procedure)
sp_post_msx_operation (Procedure)
sp_purge_jobhistory (Procedure)
sp_sqlagent_log_jobhistory (Procedure)
sp_sqlagent_notify (Procedure)
sp_sqlagent_refresh_job (Procedure)
sp_start_job (Procedure)
sp_stop_job (Procedure)
sp_sysutility_ucp_configure_policies (Procedure)
sp_sysutility_ucp_remove (Procedure)
sp_uniquetaskname (Procedure)
sp_update_alert (Procedure)
sp_update_job (Procedure)
sp_update_jobstep (Procedure)
sp_verify_alert (Procedure)
sp_verify_jobproc_caller (Procedure)
sp_verify_job_identifiers (Procedure)
sp_vupgrade_replsecurity_metadata (Procedure)
       



News

  Query a named instance
Sybase+ASE+silent+install
SQL 2008 R2
Deprecated procedures in SQL2008
Reporting Services item-level role definitions
Create all your missing indexes
Converting datetime field
Start MSSQL Server Profiler at time
Replicating MSSQL Server views
Exploring Microsoft Sharepoint
The OLE DB provider "SQLNCLI10" for linked server indicates.
Mobile solar charger
Oracle to SQL Server replication
Cannot insert the value NULL into column
Undocumented Microsoft SQL Server 2008
VMware
Zoekmachine optimalisatie
SQL Servers hidden objects
FckEditor
Flash in Ajax
De hype die AJAX heet
Barcode scannen
MySQL; Gratis, makkelijk en snel!
PHP
sIFR; de combinatie tussen HTML en Flash