Does anyone here knows how to use Groovy in data process shape to read a database field after a database SQL connector shape? Any sample code will be great. Thank you.
Basically I want to find the maximum value of one field from the select SQL statement so the maximum operation and the select SQL statement are in the same database transaction.
You can use standard Database connector operations to achieve this.
May i know why are you using groovy script for this?
I know a database connector can do this. But in my case I have a SQL select database connector and its selected data rows will be used for the next boomi shape. By the requirement I need find the maximum value of one field and it should be in the same database transaction as the SQL select statement. Another question is how do you keep two SQL statements in the same database transaction in Boomi?
You can also execute sql statements in setProperties shape to capture single value like max/count. It will not affect your previous connector's response.
Retrieving data ...