Solved

How to put a message to JMS vendor from PL/SQL?

Posted on 2004-04-28
3
1,115 Views
Last Modified: 2006-11-17
Hi,

Does any one has an examples about using PL/SQL to put a message to JMS vendor queue?
My data base is Oracle 8, and JMS vendor is MQSonic.
I know that all is easy using Oracle application server and other Oracle products, bu maybe there is free tricks?

thanks in advance,
Raimondas
0
Comment
Question by:berniunas
  • 2
3 Comments
 
LVL 8

Expert Comment

by:annamalai77
ID: 10955719
hi there

can u be bit more clear in ur query. if ur asking for auto mailing facility then try the following queries i have. i have not tried using this but this should work for u.

trigger creation
create or replace trigger automail
after insert  on ltm.GIM_ICRR_HDR for each row
DECLARE
 MAIL_FROM  VARCHAR2(50);
 MAIL_TO      VARCHAR2(50);
 SUBJECT    VARCHAR2(50);
 MAILBODY  VARCHAR2(150);
CURSOR cur_email IS
SELECT DISTINCT E_MAIL_NO FROM ltm.PUR_SUPP_MAST
WHERE SUPP_CODE = :NEW.SUPP_CODE;
sup_email  cur_email%ROWTYPE;
Begin
OPEN cur_email;
FETCH cur_email INTO  sup_email;
MAIL_FROM := 'www.LTM.com';
MAIL_TO := sup_email.E_MAIL_NO;
SUBJECT :=' New GRN NO : ' || :NEW.ICRR_NO;
MAILBODY:= 'GRN Details :-  GRN Date is   ' || :NEW.ICRR_DATE ||  '  CRR NO : ' ||
:NEW.CRR_NO || '  SUPPILER NAME :  '  || :NEW.SUPP_NAME;
auto_mail_proc(MAIL_FROM,MAIL_TO,SUBJECT,MAILBODY);
CLOSE cur_email;
End;
/

also go thru the oracle documentation for mailing
regards
annamalai
0
 

Author Comment

by:berniunas
ID: 10956220
thanks for your answer, but i need not mailing, but i need how to connect to
JMS (java message service) vendor and to put a message into a queue.

thanks again
0
 
LVL 8

Accepted Solution

by:
annamalai77 earned 250 total points
ID: 10956459
hi there

try the following link from oracle JMS.

http://otn.oracle.com/sample_code/tech/java/jsp/samples/jms/Readme.html

also try this link also

http://www.onjava.com/pub/a/onjava/2001/05/03/jms_primer.html

regards
annamalai
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This post first appeared at Oracleinaction  (http://oracleinaction.com/undo-and-redo-in-oracle/)by Anju Garg (Myself). I  will demonstrate that undo for DML’s is stored both in undo tablespace and online redo logs. Then, we will analyze the reaso…
Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
This video shows how to recover a database from a user managed backup
Via a live example, show how to restore a database from backup after a simulated disk failure using RMAN.

813 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now