Home Microsoft SQL Server DigiMailing iRN Contact
    Keyword



sys.sp_MSget_pullsubsagent_owner

  No additional text.


Syntax

create procedure sys.sp_MSget_pullsubsagent_owner (
    @publisher    sysname,
    @publisher_db sysname,
    @publication  sysname,   /* publication name */
    @owner_sid    varbinary(85) OUTPUT
    ) AS

    declare @job_id uniqueidentifier
    set nocount on

    select @owner_sid = null


    if object_id('MSreplication_subscriptions', 'U') is not NULL
    begin
        -- Get the job_id corresponding to the publication
        select @job_id = agent_id
        from MSreplication_subscriptions
        where upper(@publisher) = upper(publisher) and
            @publisher_db = publisher_db and
            @publication = publication

        -- Using the job_id in MSsubscription properties to get the owner_sid
        -- in msdb.dbo.sysjobs
        select @owner_sid = owner_sid
        from  msdb.dbo.sysjobs
        where @job_id = job_id
    end

 
Last revision 2008RTM
See also

  sp_droppullsubscription (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