[英]How to call Java File from MYSQL Stored Procedure?
I have two tables allocation_request and allocation_request_audit_logs.我有两个表allocation_request 和allocation_request_audit_logs。 I used trigger on allocation_request table, If any data insert/update on allocation_request table, trigger will call and data will insert into allocation_request_audit_logs.
我在allocation_request 表上使用了触发器,如果allocation_request 表上有任何数据插入/更新,触发器将调用并且数据将插入allocation_request_audit_logs。 But problem is, whenever allocation_request_audit_logs will update then I need to call Scheduler job.
但问题是,每当allocation_request_audit_logs 更新时,我都需要调用Scheduler 作业。 How to call Java class/code from MYSQL Stored Procedure?
如何从 MYSQL 存储过程调用 Java 类/代码?
Yes, it is possible to call Java code directly from a MySQL stored procedure through a UDF
or User Defined Function
.是的,可以通过
UDF
或User Defined Function
直接从 MySQL 存储过程调用 Java 代码。
Take a look at this other answer:看看这个另一个答案:
https://stackoverflow.com/a/9777662/236528 https://stackoverflow.com/a/9777662/236528
And more details here on how to make it work:以及有关如何使其工作的更多详细信息:
https://dba.stackexchange.com/a/39547/3257 https://dba.stackexchange.com/a/39547/3257
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.