JobServer Members

The JobServer object represents the Microsoft SQL Server Agent subsystem and the MSDB database.

The following tables list the members exposed by the JobServer type.

Protected Fields

  名称 Description
ms219114.protfield(zh-cn,SQL.90).gif m_ExtendedProperties  (inherited from SqlSmoObject )

顶部

Public Properties

(see also Protected Properties )

  名称 Description
ms219114.pubproperty(zh-cn,SQL.90).gif AgentLogLevel Gets or sets the type of messages that are logged by Microsoft SQL Server Agent.
ms219114.pubproperty(zh-cn,SQL.90).gif AgentMailType Gets or sets the mail type for Microsoft SQL Server Agent.
ms219114.pubproperty(zh-cn,SQL.90).gif AgentShutdownWaitTime Gets or sets the time that Microsoft SQL Server Agent waits for jobs to complete execution before shutting down.
ms219114.pubproperty(zh-cn,SQL.90).gif AlertCategories Represents a collection of AlertCategory objects. Each AlertCategory object represents an alert category defined on Microsoft SQL Server Agent.
ms219114.pubproperty(zh-cn,SQL.90).gif Alerts Represents a collection of Alert objects. Each Alert object represents an alert defined on Microsoft SQL Server Agent.
ms219114.pubproperty(zh-cn,SQL.90).gif AlertSystem The AlertSystem object stores information that applies to all the alerts defined on Microsoft SQL Server Agent.
ms219114.pubproperty(zh-cn,SQL.90).gif DatabaseMailProfile Gets or sets a Database Mail profile.
ms219114.pubproperty(zh-cn,SQL.90).gif ErrorLogFile Gets or sets the name and path of the file in which Microsoft SQL Server Agent records errors.
ms219114.pubproperty(zh-cn,SQL.90).gif HostLoginName Gets or sets the logon used to log on to Microsoft SQL Server.
ms219114.pubproperty(zh-cn,SQL.90).gif IdleCpuDuration Gets or sets the length of time in seconds that the processor must have to maintain the CPU idle percentage value before the processor is considered idle.
ms219114.pubproperty(zh-cn,SQL.90).gif IdleCpuPercentage Gets or sets the CPU idle percentage threshold that the processor is required to achieve before it is considered idle.
ms219114.pubproperty(zh-cn,SQL.90).gif IsCpuPollingEnabled Gets or sets the Boolean property value that specifies whether CPU polling is enabled.
ms219114.pubproperty(zh-cn,SQL.90).gif JobCategories Represents a collection of JobCategory objects. Each JobCategory object represents a job category defined on Microsoft SQL Server Agent.
ms219114.pubproperty(zh-cn,SQL.90).gif Jobs Represents a collection of Job objects. Each Job object represents a job defined on Microsoft SQL Server Agent.
ms219114.pubproperty(zh-cn,SQL.90).gif JobServerType Gets or sets the type of job server with regard to multiserver administration.
ms219114.pubproperty(zh-cn,SQL.90).gif LocalHostAlias Gets or sets the local host alias that is used to connect to the local instance of Microsoft SQL Server.
ms219114.pubproperty(zh-cn,SQL.90).gif LoginTimeout Gets or sets the number of seconds after which an attempt to connect times out.
ms219114.pubproperty(zh-cn,SQL.90).gif MaximumHistoryRows Gets or sets the maximum number of history rows retained.
ms219114.pubproperty(zh-cn,SQL.90).gif MaximumJobHistoryRows Gets or sets the maximum number of history rows retained per job.
ms219114.pubproperty(zh-cn,SQL.90).gif MsxAccountCredentialName Gets or sets the Microsoft Windows account required to connect to the master server using Windows Authentication.
ms219114.pubproperty(zh-cn,SQL.90).gif MsxAccountName Gets or sets the logon required to connect to the master server using Microsoft SQL Server Authentication.
ms219114.pubproperty(zh-cn,SQL.90).gif MsxServerName Gets or sets the name of the master server participating in multiserver administration.
ms219114.pubproperty(zh-cn,SQL.90).gif Name  Gets or sets the name of the object. (inherited from NamedSmoObject)
ms219114.pubproperty(zh-cn,SQL.90).gif NetSendRecipient Gets or sets the recipient of net send messages.
ms219114.pubproperty(zh-cn,SQL.90).gif OperatorCategories Represents a collection of OperatorCategory objects. Each OperatorCategory object represents an operator category defined on Microsoft SQL Server Agent.
ms219114.pubproperty(zh-cn,SQL.90).gif Operators Represents a collection of Operator objects. Each Operator object represents an operator defined on Microsoft SQL Server Agent.
ms219114.pubproperty(zh-cn,SQL.90).gif Parent Gets the Server object that is the parent of the JobServer object.
ms219114.pubproperty(zh-cn,SQL.90).gif Properties  Gets a collection of Property objects that represent the object properties. (inherited from SqlSmoObject)
ms219114.pubproperty(zh-cn,SQL.90).gif ProxyAccounts Represents a collection of ProxyAccount objects. Each ProxyAccount object represents a proxy account defined on Microsoft SQL Server Agent.
ms219114.pubproperty(zh-cn,SQL.90).gif ReplaceAlertTokensEnabled  
ms219114.pubproperty(zh-cn,SQL.90).gif SaveInSentFolder Gets or sets the Boolean property value that specifies whether the notifications are saved.
ms219114.pubproperty(zh-cn,SQL.90).gif SharedSchedules Represents a collection of JobSchedule objects. Each JobSchedule object represents a shared schedule defined on Microsoft SQL Server Agent.
ms219114.pubproperty(zh-cn,SQL.90).gif SqlAgentAutoStart Gets or sets the Boolean property value that specifies whether SQL Server Agent is automatically started.
ms219114.pubproperty(zh-cn,SQL.90).gif SqlAgentMailProfile Gets or sets a Microsoft SQL Server Agent mail profile.
ms219114.pubproperty(zh-cn,SQL.90).gif SqlAgentRestart Gets or sets the Boolean property value that specifies whether SQL Server Agent is monitored and restarted if it stops.
ms219114.pubproperty(zh-cn,SQL.90).gif SqlServerRestart Gets or sets the Boolean property value that specifies whether the Microsoft SQL Server Service is monitored and restarted if it stops.
ms219114.pubproperty(zh-cn,SQL.90).gif State  Gets the state of the referenced object. (inherited from SmoObjectBase)
ms219114.pubproperty(zh-cn,SQL.90).gif SysAdminOnly Gets the Boolean property value that specifies whether CmdExec and ActiveX commands can only be executed by members of the sysadmins fixed server role.
ms219114.pubproperty(zh-cn,SQL.90).gif TargetServerGroups Represents a collection of TargetServerGroup objects. Each TargetServerGroup object represents a target server group defined on Microsoft SQL Server Agent.
ms219114.pubproperty(zh-cn,SQL.90).gif TargetServers Represents a collection of TargetServer objects. Each TargetServer object represents a target server defined on Microsoft SQL Server Agent.
ms219114.pubproperty(zh-cn,SQL.90).gif Urn  Gets the Uniform Resource Name (URN) address value that uniquely identifies the object. (inherited from SqlSmoObject)
ms219114.pubproperty(zh-cn,SQL.90).gif UserData  Gets or sets user-defined data associated with the referenced object. (inherited from SmoObjectBase)
ms219114.pubproperty(zh-cn,SQL.90).gif WriteOemErrorLog Gets or sets the Boolean property value that specifies whether to write the error log to a non-Unicode file or not.

顶部

Protected Properties

  名称 Description
ms219114.protproperty(zh-cn,SQL.90).gif ExecuteForScalar  Gets or sets the Boolean property value that specifies whether the object is set to the execute for scalar option. (inherited from SqlSmoObject)
ms219114.protproperty(zh-cn,SQL.90).gif ObjectInSpace  Gets the Boolean property value that specifies whether the object exists in isolation or whether it is connected to the instance of Microsoft SQL Server directly or indirectly. (inherited from SqlSmoObject)
ms219114.protproperty(zh-cn,SQL.90).gif PresetProperties  Gets or sets the preset properties of the referenced object. (inherited from SqlSmoObject)
ms219114.protproperty(zh-cn,SQL.90).gif ScalarResult  Gets the scalar result for the referenced object. (inherited from SqlSmoObject)

顶部

Public Methods

(see also Protected Methods )

  名称 Description
ms219114.pubmethod(zh-cn,SQL.90).gif Alter Updates any JobServer object property changes on an instance of Microsoft SQL Server.
ms219114.pubmethod(zh-cn,SQL.90).gif ClearHostLoginAccount Clears the host logon account and uses integrated security to log on to Microsoft SQL Server.
ms219114.pubmethod(zh-cn,SQL.90).gif ClearMsxAccount Clears the master server logon account and uses integrated security to log on to the master server.
ms219114.pubmethod(zh-cn,SQL.90).gif CycleErrorLog Closes and renames the current error log, and then creates a new empty error log file.
ms219114.pubmethod(zh-cn,SQL.90).gif DropJobByID Removes the job with the specified ID value.
ms219114.pubmethod(zh-cn,SQL.90).gif DropJobsByLogin Removes the job with the specified logon name.
ms219114.pubmethod(zh-cn,SQL.90).gif DropJobsByServer Removes the job with the specified server.
ms219114.pubmethod(zh-cn,SQL.90).gif EnumErrorLogs Enumerates a list of Microsoft SQL Server Agent error log information.
ms219114.pubmethod(zh-cn,SQL.90).gif EnumJobHistory Overloaded. Enumerates a list of Microsoft SQL Server Agent job history information.
ms219114.pubmethod(zh-cn,SQL.90).gif EnumJobs Overloaded. Enumerates a list of information about the current job.
ms219114.pubmethod(zh-cn,SQL.90).gif EnumPerformanceCounters Overloaded. Enumerates a list of Microsoft SQL Server Agent performance counter information.
ms219114.pubmethod(zh-cn,SQL.90).gif EnumSubSystems Enumerates a list of Microsoft SQL Server Agent execution subsystems.
ms219114.pubmethod(zh-cn,SQL.90).gif Equals  Overloaded. (inherited from Object )
ms219114.pubmethod(zh-cn,SQL.90).gif GetHashCode  (inherited from Object )
ms219114.pubmethod(zh-cn,SQL.90).gif GetJobByID Returns a job with the specified ID value.
ms219114.pubmethod(zh-cn,SQL.90).gif GetType  (inherited from Object )
ms219114.pubmethod(zh-cn,SQL.90).gif Initialize  Overloaded. Initializes the object and forces the properties be loaded. (inherited from SqlSmoObject)
ms219114.pubmethod(zh-cn,SQL.90).gif MsxDefect Overloaded. Ends Microsoft SQL Server Agent participation in a multiserver administration group
ms219114.pubmethod(zh-cn,SQL.90).gif MsxEnlist Enlists Microsoft SQL Server Agent as a target server with the specified master server in a multiserver administration.
ms219114.pubmethod(zh-cn,SQL.90).gif PurgeJobHistory Overloaded. Removes all logged records of Microsoft SQL Server Agent jobs.
ms219114.pubmethod(zh-cn,SQL.90).gif ReadErrorLog Overloaded. Enumerates the error log.
ms219114.pubmethod(zh-cn,SQL.90).gif ReassignJobsByLogin Changes ownership for any Microsoft SQL Server Agent job currently owned by a Microsoft SQL Server logon.
ms219114.pubmethod(zh-cn,SQL.90).gifms219114.static(zh-cn,SQL.90).gif ReferenceEquals  (inherited from Object )
ms219114.pubmethod(zh-cn,SQL.90).gif Refresh  Refreshes the object and retrieves properties when the object is next accessed. (inherited from SqlSmoObject)
ms219114.pubmethod(zh-cn,SQL.90).gif RemoveJobByID Removes a job with a specified ID value.
ms219114.pubmethod(zh-cn,SQL.90).gif RemoveJobsByLogin Removes a job with a specified logon.
ms219114.pubmethod(zh-cn,SQL.90).gif Script Overloaded. Generates a Transact-SQL script that can be used to re-create SQL Server Agent.
ms219114.pubmethod(zh-cn,SQL.90).gif SetHostLoginAccount Sets the Microsoft SQL Server Authentication account and password used to log on to SQL Server.
ms219114.pubmethod(zh-cn,SQL.90).gif SetMsxAccount Overloaded. Sets the name of the credentials used to log on to the master server in multiserver administration.
ms219114.pubmethod(zh-cn,SQL.90).gif StartMonitor Starts monitoring the local Microsoft SQL Server Agent Service by an instance of SQL Server.
ms219114.pubmethod(zh-cn,SQL.90).gif StopMonitor Ends monitoring the local Microsoft SQL Server Agent Service by an instance of SQL Server.
ms219114.pubmethod(zh-cn,SQL.90).gif TestMailProfile Tests the validity of an e-mail profile.
ms219114.pubmethod(zh-cn,SQL.90).gif TestNetSend Tests the validity of a net send address.
ms219114.pubmethod(zh-cn,SQL.90).gif ToString  Returns a String that represents the referenced object. (inherited from SqlSmoObject)

顶部

Protected Methods

  名称 Description
ms219114.protmethod(zh-cn,SQL.90).gif AlterImpl  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif AlterImplFinish  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif AlterImplInit  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif AlterImplWorker  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif BindDefaultImpl  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif BindRuleImpl  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif CheckCollation  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif CheckObjectState  Overloaded. Validates the state of the referenced object. (inherited from SqlSmoObject)
ms219114.protmethod(zh-cn,SQL.90).gif CheckObjectStateImpl  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif CheckVersion80  Checks the validity of the object on Microsoft SQL Server 2000. (inherited from SqlSmoObject)
ms219114.protmethod(zh-cn,SQL.90).gif CheckVersion80SP3  Checks the validity of the object on Microsoft SQL Server 2000 SP3. (inherited from SqlSmoObject)
ms219114.protmethod(zh-cn,SQL.90).gif CheckVersion90  Check the validity of the object on Microsoft SQL Server 2005. (inherited from SqlSmoObject)
ms219114.protmethod(zh-cn,SQL.90).gif CheckVersionBelow90  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif CleanObject  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif CreateImpl  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif CreateImplFinish  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif CreateImplInit  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif DropImpl  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif DropImplWorker  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif Finalize  (inherited from Object )
ms219114.protmethod(zh-cn,SQL.90).gif FormatSqlVariant  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GenerateDataSpaceScript  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetBindDefaultScript  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetBindRuleScript  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetBoolParameter  Overloaded. (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetDateTimeParameter  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetDateTimeParameterAsInt  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetDBName  Gets the name of the database with which Microsoft SQL Server Agent is associated. (inherited from AgentObjectBase)
ms219114.protmethod(zh-cn,SQL.90).gif GetEnumParameter  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetFragOptionString  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetGuidParameter  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetParameter  Overloaded. (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetPropValue  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetPropValueOptional  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetPropValueOptionalAllowNull  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetRealValue  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetScriptingOptionsForCreate  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetServerName  Gets the name of the instance of Microsoft SQL Server with which the object is associated. (inherited from SqlSmoObject)
ms219114.protmethod(zh-cn,SQL.90).gif GetSqlServerVersionName  Gets the version name of the instance of Microsoft SQL Server with which the object is associated. (inherited from SqlSmoObject)
ms219114.protmethod(zh-cn,SQL.90).gif GetStringParameter  Overloaded. (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetTimeSpanParameterAsInt  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif GetUrnRecursive  Overloaded. (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif ImplInitialize  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gifms219114.static(zh-cn,SQL.90).gif IsCollectionDirty  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif IsObjectDirty  Verifies whether the object properties have been modified and the changes have not yet been persisted on the instance of Microsoft SQL Server. (inherited from SqlSmoObject)
ms219114.protmethod(zh-cn,SQL.90).gif IsObjectInitialized  Verifies whether the object has been initialized. (inherited from SqlSmoObject)
ms219114.protmethod(zh-cn,SQL.90).gif IsObjectInSpace  Verifies whether the object is isolated or connected to the instance of Microsoft SQL Server. (inherited from SqlSmoObject)
ms219114.protmethod(zh-cn,SQL.90).gif IsVersion80SP3  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif MarkDropped  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif MarkForDropImpl  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif MemberwiseClone  (inherited from Object )
ms219114.protmethod(zh-cn,SQL.90).gif PostAlter  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif PostCreate  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif PostDrop  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif RenameImpl  (inherited from NamedSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif RenameImplWorker  (inherited from NamedSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif ScriptAlter  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif ScriptChangeOwner  (inherited from NamedSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif ScriptCreate  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif ScriptDdl  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif ScriptDrop  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif ScriptImpl  Overloaded. (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif ScriptImplWorker  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif ScriptRename  (inherited from NamedSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif SetParentImpl  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gifms219114.static(zh-cn,SQL.90).gif Trace  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif UnbindDefaultImpl  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gif UnbindRuleImpl  (inherited from SqlSmoObject )
ms219114.protmethod(zh-cn,SQL.90).gifms219114.static(zh-cn,SQL.90).gif UpdateCollectionState2  (inherited from SqlSmoObject )

顶部

请参阅

参考

JobServer Class
Microsoft.SqlServer.Management.Smo.Agent Namespace

其他资源

自动执行管理任务(SQL Server 代理)
Scheduling Automatic Administrative Tasks in SQL Server Agent
SQL Server 代理存储过程 (Transact-SQL)