SoftTree Technologies SoftTree Technologies
Technical Support Forums
RegisterSearchFAQMemberlistUsergroupsLog in
DB MAIL

 
Reply to topic    SoftTree Technologies Forum Index » DB Audit, DB Mail, DB Tools View previous topic
View next topic
DB MAIL
Author Message
Walid Nsouli



Joined: 01 Feb 2000
Posts: 1

Post DB MAIL Reply with quote

how to write a database trigger on one of the tables that will email me if anyone added new record on that table ?????

Tue Oct 24, 2000 12:38 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7839

Post Re: DB MAIL Reply with quote

This is exactly the case on http://www.softtreetech.com/dbmail/examples.htm
page. It is similar to SELECT send_main(...) FROM customers.
: Do you have more samples on how to send mail from SQL or PL/SQL ???
: like if I want to send to all customers on email

Tue Oct 24, 2000 1:27 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7839

Post Re: DB MAIL Reply with quote

CREATE OR REPLACE TRIGGER trigger_name AFTER INSERT ON table_name FOR EACH ROW
DECLARE
ret_code NUMBER;
BEGIN
ret_code := send_mail( your_email_address, 'New record inserted',

'Time: ' || SYSTIME || ', User: ' || user, your_email_address );
END;

: how to write a database trigger on one of the tables that will email me if
: anyone added new record on that table ?????

Tue Oct 24, 2000 1:36 pm View user's profile Send private message
Display posts from previous:    
Reply to topic    SoftTree Technologies Forum Index » DB Audit, DB Mail, DB Tools All times are GMT - 4 Hours
Page 1 of 1

 
Jump to: 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


 

 

Powered by phpBB © 2001, 2005 phpBB Group
Design by Freestyle XL / Flowers Online.