To call a batch file for renaming the file with a unique identifier for Adeptia:AS2 message information is needed to record in Adeptia log database for further integration and processing. You need to insert the data in the SQL table.
- Access Adeptia log database and ensure it has the table name “AU_AS2Logs”. Please create the table if it is not available.
- Login to the JSCAPE MFT Server Web Interfaceweb interface.
- Go to the Domains tab, select the domain, and click Edit.
- Select Triggers from the left pane of the window.Click Addmenu.
- In the Triggers tab, select the same trigger that was created for Run Process Action and click Edit.
The Add Edit Trigger window appears. - Click Next and go to Trigger Action window.
- Provide the name and description of the trigger.
- Select "File Upload" in the Event Type On the Trigger Action window, click Add.
The Add Action window appears. - Select SQL Query from the Action drop-down list.
- Click Next.
- Move to Trigger Action window and select the Action as "Run Process". Click OK.
- Provide the absolute file path and file name in the Program text box for your batch file.
- Define the space separated arguments in the Arguments text box. You can also use predefined variables.
- Provide the name and path for the batch execution in the Output Stream and Error Stream text boxes respectively.
Click OK.Click OK to define the SQL credentials.Info Click Add Variable to use predefined variables for getting the path and file name of the uploaded file.
Click Add Function to use predefined functions in JSCAPE.
The SQL Query Action window appears. - Provide the jdbc credentials in the respective fields and type your SQL query that you want to execute through the trigger. Click Add Variable to insert AS2 message data into the table dynamically with the help of prebuilt variables provided by JSCAPE Server.
- Click OK.
Info You need to put the jdbc driver jar respective to the Database server in use, in the libs directory of the default installation directory of the JSCAPE server.
Also, you need to make an entry of the JDBC class in the Server > Settings > JDBC Drivers before using SQL Query Action. Click OK to apply the new changes.