Problem with Queue

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for Oracle
Post Reply
__SB
Posts: 1
Joined: Wed 05 Oct 2011 07:58

Problem with Queue

Post by __SB » Wed 05 Oct 2011 08:28

Good day, while working with dotConnect I had a glitch. I need to send a message to the queue, but the message type: AQ $ _JMS_BYTES_MESSAGE. My question is, as from C # to send the message of this type.

UPDATE:
And here's the source code in which we are trying to send a message to the queue. But this is only an error ORA-30 625

Code: Select all

OracleConnection Connection = new OracleConnection(ConnectionString);
                Connection.Open();
				OracleQueue oq = new OracleQueue("EXPORT_DATA",Connection);
                OracleObject obj = new OracleObject("SYS.AQ$_JMS_BYTES_MESSAGE", Connection);
			   OracleParameterCollection OPC = new OracleParameterCollection();
                OPC.Add("property_name",(object)("FileName"));
                OPC.Add("property_value",(object)("12345.xml"));
                obj.ExecuteMethod(Connection, "set_string_property", OPC);
               OracleObject.ExecuteMethod(obj,Connection,"SYS.AQ$_JMS_BYTES_MESSAGE", "set_string_property", OPC);
               obj["msg_type"] = "POSLog";
               oq.Enqueue(obj);

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Post by Shalex » Tue 11 Oct 2011 09:27

AQ$_JMS_BYTES_MESSAGE can not be used via the OracleObject class. We recommend you to use messages of some user-defined type (UDT) like the one from A Simple Example of Point-to-Point Messaging: http://www.devart.com/dotconnect/oracle/docs/?AQ.html.

Post Reply