zoukankan      html  css  js  c++  java
  • SSB FAQ (2) – Create a stored procedure as a service program

    SSB FAQ (2) – Create a stored procedure as a service program

     

    The following code snippet shows you how to create a stored procedure as a service program.

     

    CREATE QUEUE [dbo].[Queue_OutStock_Out] WITH STATUS = ON , RETENTION = OFF ,

    ACTIVATION

    (  STATUS = ON ,

    PROCEDURE_NAME = [dbo].[usp_OutStock_OnReceiveMessage] ,

    MAX_QUEUE_READERS = 5 , EXECUTE AS N'dbo'

    )

     

    Arguments:

    RETENTION

    Specifies the retention setting for the queue. If RETENTION = ON, all messages sent or received on conversations using this queue are retained in the queue until the conversations have ended. Setting RETENTION = ON can reduce performance. The default value for REENTION is OFF.

     

    MAX_QUEUE_READERS = max_readers

    Specifies the maximum number of instances of the activation stored procedure that the queue starts at the same time.

     

    You can temporarily disable activation action by executing the following script.

    Alter Queue Queue_OutStock_Out WITH ACTIVATION (STATUS=OFF)

     

    The URL below has more detail.

    SQL Server 2005 Beta 2 Service Broker: Stored Procedure acts as a service program

    http://www.cnblogs.com/rickie/archive/2005/04/16/138658.html

     

     

     

  • 相关阅读:
    Vue自定义指令 directive
    Vue过滤器 filters
    贪心
    家庭作业
    线段
    数列极差
    shell
    智力大冲浪
    加工生产调度
    喷水装置
  • 原文地址:https://www.cnblogs.com/rickie/p/605408.html
Copyright © 2011-2022 走看看