返回有关发布的信息。该存储过程在发布服务器的发布数据库上执行。
sp_helppublication [ [ @publication = ] 'publication' ]
[ , [ @found =] found OUTPUT]
[@publication =] 'publication'
是要查看的发布名称。publication 的数据类型为 sysname,默认设置为 %,表示返回有关所有发布的信息。
[@found =] 'found' OUTPUT
是表示返回行的标记。found 的数据类型为 int,而且是 OUTPUT 参数,默认值为 23456。1 表示已找到发布。0 表示未找到发布。
列名 | 数据类型 | 描述 |
---|---|---|
pubid | int | 发布的 ID。 |
name | sysname | 发布名称。 |
restricted | int | 未使用,设置为 0。 |
status | tinyint | 发布数据的可用时间。 |
task | 用于向后兼容。 | |
replication frequency | tinyint | 复制频率的类型:
0 = 基于事务 |
synchronization method | tinyint | 同步模式:
0 = 本机大容量复制程序(bcp 实用工具) |
description | nvarchar(255) | 对发布的可选描述。 |
immediate_sync | bit | 表示每次快照代理程序运行时是否创建或重新创建同步文件。 |
enabled_for_internet | bit | 表示是否通过 FTP 和其它服务将发布的同步文件表现在 Internet 上。 |
allow_push | bit | 表示是否允许在发布上使用强制订阅。 |
allow_pull | bit | 表示是否允许在发布上使用请求订阅。 |
allow_anonymous | bit | 表示是否允许在发布上使用匿名订阅。 |
independent_agent | bit | 表示是否有用于该发布的独立分发代理程序。 |
immediate_sync_ready | bit | 表示快照代理程序是否生成了准备由新订阅使用的快照。只有当发布被设置为始终有可用于新订阅或重新初始化订阅的快照,才定义该参数。 |
allow_sync_tran | bit | 表示是否允许在发布上使用即时更新订阅。 |
autogen_sync_procs | bit | 表示是否自动生成存储过程以支持即时更新订阅。 |
snapshot_jobid | binary(16) | 已调度任务 ID。 |
retention | int | 为给定的发布保存的更改量(以小时为单位)。 |
sp_helppublication 用于快照复制和事务复制。
执行权限默认授予 public 角色。