Support Questions

Find answers, ask questions, and share your expertise

Does ExecuteSQL processor allow to execute stored procedure ?

avatar

Can I execute stored procedure on database using ExecuteSQL proessor ? Is there any sample ?

1 ACCEPTED SOLUTION

avatar
Master Mentor

I don't think so but maybe you can wrap the exec storedprocedure into a shell script or groovy and run it in ExecuteProcess/ExecuteScript?

View solution in original post

23 REPLIES 23

avatar
Explorer

Hi,

 

I have two separate flow files (one for insert and one for delete) which works fine. And in the end i put Output port.

LejlaKM_0-1644584978190.png

 

After that job is done I need to execute plsql procedure from destination database., so I made another process group with input port and another flow

LejlaKM_1-1644585147855.png

Processor generate table fetch selecting max and min date from one table like this

LejlaKM_2-1644585255939.png

And after that I need those two values to pass to plsql procedure and I don't know how.

Last processor putsql look like this

LejlaKM_3-1644585346959.png

and when I have no parameter to pass all works fine, but I need those parameter to pas

I hope that you can help me with this. I am new in nifi as you can see

avatar
Explorer

You need to use some processor to extract the info of the flowfile. For example, you can use ExtractText processor after generated table fetch proccesors. The result of this (ExtractText) processor is the atribute you need to use next (max and min) but depend how you configure you will have the same flowfile or not. This is important to the flow in the next steps (if you need to use again).

You can find information of ExtractText processor here ExtractText processor 

And this is te documentation web page of nifi.

 

Sorry for my english.

avatar
Contributor

Hi Can tell me what is package and body

avatar
Explorer

Hi..
You can find more information here