Home Microsoft SQL Server DigiMailing iRN Contact
    Keyword



sys.sp_adddistpublisher

  No additional text.


Syntax
create procedure sys.sp_adddistpublisher
(
    @publisher				sysname,
    @distribution_db		sysname,
    @security_mode			int = 1,
    @login					sysname = NULL,
    @password				sysname = NULL,
    @working_directory		nvarchar(255) = NULL,
    @trusted				nvarchar(5) = 'false',
    @encrypted_password		bit = 0,
    @thirdparty_flag		bit = 0,
    @publisher_type			sysname = N'MSSQLSERVER'
)
AS
BEGIN
	DECLARE @cmd		nvarchar(4000)
	DECLARE @retcode	int

	SET @retcode = 0
	SET @cmd = N''

	-- DEPRECATED PARAMETER: @trusted
	-- For security reasons, @trusted is no longer supported.
	-- Implicitly, it must always be @trusted == false.  If
	-- anything other than false is supplied, an error is thrown.
    IF LOWER(@trusted collate SQL_Latin1_General_CP1_CS_AS) NOT IN ('false')
	BEGIN
		RAISERROR(21698, 16, -1, '@trusted')
		RETURN (1)
	END
	
	-- Check if HREPL
	IF NOT @publisher_type = N'MSSQLSERVER'
	BEGIN
		SET @cmd = @cmd + QUOTENAME(@distribution_db) + N'.'
	END

	-- Add sp
	SET @publisher = UPPER(@publisher) COLLATE DATABASE_DEFAULT
	set @cmd = @cmd + N'sys.sp_MSrepl_adddistpublisher'
	
	EXEC @retcode = @cmd
					@publisher,
					@distribution_db,
					@security_mode,
					@login,
					@password,
					@working_directory,
					@trusted,
					@encrypted_password,
					@thirdparty_flag,
					@publisher_type

	RETURN (@retcode)
END

 
Last revision 2008RTM
See also

  sp_MSadd_logreader_agent (Procedure)
sp_MSadd_merge_agent (Procedure)
sp_MSadd_snapshot_agent (Procedure)
sp_MSchange_logreader_agent_properties (Procedure)
sp_MSchange_snapshot_agent_properties (Procedure)
sp_MSdrop_replcom (Procedure)
sp_MSrepl_adddistpublisher (Procedure)
sp_MSrepl_addlogreader_agent (Procedure)
sp_MSrepl_addpublication_snapshot (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