Quantcast
Channel: Apache Timeline
Viewing all articles
Browse latest Browse all 5648

Running a delete query within a route

$
0
0
I have a route that does a number of things:

.process(lookupToHeadersProcessor) // 1) converts input parameters to headers
.to("bean:myStoredProcedure") // 2) calls a stored procedure, that enters a record in a TEMP table and returns the ID
.recipientList(simple("sql:select ret_string from TEMP " +
"where seq = ${body['v_num']}?dataSource=ds.customerName")) // 3) executes a query to get a string
// todo: DELETE from TEMP where seq = v_num;
.marshal().string("UTF-8") // 4) converts input string to string for CSV parsing
.unmarshal(csv) // 5) converts string to fields
.process(memberLookupProcessor) // 6) convert List<List<String>> from unmarshalling to Member object

How can I execute the DELETE query above w/o modifying the output between route steps? I believe if I input it in the location above, the string won't be returned from the previous step.

Thanks,

Matt

Viewing all articles
Browse latest Browse all 5648

Trending Articles