|
RPGLE programs can be registered as stored procedures and then executed
with the CALL SQL command (in an SQL trigger or any other SQL Routine or
any environment where SQL statements can be performed).
Even though it is possible to call RPGLE directly from SQL it is much
better registering them as stored procedure for avoiding parameter mismatch.
Mit freundlichen Grüßen / Best regards
Birgitta Hauser
"Shoot for the moon, even if you miss, you'll land among the stars." (Les
Brown)
"If you think education is expensive, try ignorance." (Derek Bok)
"What is worse than training your staff and losing them? Not training them
and keeping them!"
-----Ursprüngliche Nachricht-----
Von: MIDRANGE-L [mailto:midrange-l-bounces@xxxxxxxxxxxx] Im Auftrag von
Jeff Young
Gesendet: Tuesday, 24.3 2015 22:11
An: Midrange Systems Technical Discussion
Betreff: Re: SQL Trigger Information
Henrik/Rob,
Thanks for the info on the SQL Trigger.
Is it possible to have the trigger call an RPGLE program when the column
is changed?
Jeff Young
Sr. Programmer Analyst
On Tue, Mar 24, 2015 at 5:05 PM, Henrik Rützou <hr@xxxxxxxxxxxx> wrote:
I'm actually working on a little project that records changes on--
specific important fields across tables - a who did that and when -
product.
On Tue, Mar 24, 2015 at 10:00 PM, <rob@xxxxxxxxx> wrote:
A simple search of the Knowledge Center for sql trigger turned up ahttp://www-01.ibm.com/support/knowledgecenter/ssw_ibm_i_72/sqlp/rbafya
good hit. I think you want an "after" trigger such as
create trigger mytrigger
after update of MyColumn on MyTable
...
See:
ftersql.htm?lang=en-us
Rob Berendt
--
IBM Certified System Administrator - IBM i 6.1 Group Dekko Dept 1600
Mail to: 2505 Dekko Drive
Garrett, IN 46738
Ship to: Dock 108
6928N 400E
Kendallville, IN 46755
http://www.dekko.com
From: Jeff Young <jyoung0950@xxxxxxxxx>
To: Midrange Systems Technical Discussion <midrange-l@xxxxxxxxxxxx
Date: 03/24/2015 04:31 PMlist
Subject: SQL Trigger Information
Sent by: "MIDRANGE-L" <midrange-l-bounces@xxxxxxxxxxxx>
I have a file that I would like to setup a trigger for when selected
fields are changed or a record is added and have it call an RPGLE
program.
Can I do this with SQL?
If so, does anyone have an example to share?
System is at V6R1M1.
TIA
Jeff Young
Sr. Programmer Analyst
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L)
mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To
subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please
take a moment to review the archives at
http://archive.midrange.com/midrange-l.
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L)
mailing
To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please
take a moment to review the archives at
http://archive.midrange.com/midrange-l.
--
Regards,
Henrik Rützou
http://powerEXT.com <http://powerext.com/>
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take
a moment to review the archives at
http://archive.midrange.com/midrange-l.
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a
moment to review the archives at http://archive.midrange.com/midrange-l.
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.