Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8478273
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T18:42:01+00:00 2026-06-10T18:42:01+00:00

I am trying to insert data into queue. The stored procedure fire_event will be

  • 0

I am trying to insert data into queue. The stored procedure fire_event will be used for this purpose. When ever this stored procedure is called, it should insert that data into the queue.. Below is the query and variables that will be passed from the stored procedure. Can some one tell me how to use this stored procedure to insert data in a queue in SQL Server. I want to replace the action of inserting into a table event_type by inserting it directly into a queue. Thanks

BEGIN

INSERT event_type
VALUES (@p_message_id,@p_event_type,@p_classifier,
        @p_event_time,@p_correlation_id,@p_person_id,@p_channel_id,
        @p_source_address_id,@p_agent_user,
        @p_agent_channel_id,@p_device_os,@p_device_os_version,
        @p_device_manufacturer,@p_device_model,@p_product_id,
        @p_event_source,@p_event_version,
        @p_node_id,@p_user_agent_string,@p_event_data)

END 
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T18:42:02+00:00Added an answer on June 10, 2026 at 6:42 pm

    If you really mean Service Broker, then you should use SEND command.

    For example, Service Broker objects:

    Create Queue MyTableQueue;
    Create Service MyTableService On Queue MyTableQueue([DEFAULT])
    Create Queue  ProcessQueue;
    Create Service ProcessService On Queue ProcessQueue([DEFAULT])
    

    To send message:

    Declare @h UniqueIdentifier;
    Declare @doc xml;
    
    Set @doc =
    (
        Select 'Hello' Msg
        For XML Raw, Elements, Type, Root('Data')
    );
    Begin Dialog Conversation @h
    From Service MyTableService
        To Service 'ProcessService'
    With Encryption = OFF;
    
    Send On Conversation @h(@doc)
    

    or in your case (+ column aliases):

    Declare @h UniqueIdentifier;
    Declare @doc xml;
    
    Set @doc =
    (
        Select @p_message_id,@p_event_type,@p_classifier,@p_event_time,@p_correlation_id,@p_person_id,@p_channel_id,@p_source_address_id,@p_agent_user,
               @p_agent_channel_id,@p_device_os,@p_device_os_version,@p_device_manufacturer,@p_device_model,@p_product_id,@p_event_source,@p_event_version,
               @p_node_id,@p_user_agent_string,@p_event_data
        For XML Raw, Elements, Type, Root('Data')
    );
    
    Begin Dialog Conversation @h
    From Service MyTableService
        To Service 'ProcessService'
    With Encryption = OFF;
    
    Send On Conversation @h(@doc)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am currently trying to insert data into a table called customer_quote , this
I'm trying to insert data into my SQlite3 database (this works via the command
I am getting this error when trying to insert data into a data table
I'm trying to insert data into a table using a plpgsql function or stored
I'm trying to insert data into the SQLite database using get EditText, but I
I am trying to insert data into a table in sorted order, for later
Getting a strange error when trying to insert data into an Access database using
I am trying to insert some data into a pysqlite database but even tho
I have a form that is trying to insert some data into an SQL
I am trying to insert some text data into a table in SQL Server

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.