Ask questions about installing and configuring ProcessMaker 3
User avatar
By amosbatto
#824846
It would be much easier to use Amazon's MySQL or PostgreSQL because you can connect to them using a standard Database Connection in ProcessMaker.

From what I read, Amazon Aurora Serverless is supposed to have a MySQL compatibility mode, so may be possible to connect as a standard Database Connection. I don't have AWS, so you will have to test it and tell us what happens.

What I did find by googling the topic was this Data API:
https://aws.amazon.com/blogs/aws/new-da ... erverless/

You can follow these instructions to install the "aws" command on your ProcessMaker server.

Then, you can use PHP's exec() function in a ProcessMaker trigger to execute an "aws" command on your server to get data from Aurora Serverless.

From reading the documentation, I imagine that your trigger would be something like this:
Code: Select all
$cmd = 'aws rds-data execute-statement ' .
  ' --secret-arn "arn:aws:secretsmanager:us-east-1:123456789012:secret:aurora-serverless-data-api-sl-admin-2Ir1oL" '. 
  ' --resource-arn "arn:aws:rds:us-east-1:123456789012:cluster:aurora-sl-1" '.
  ' --database users '.
  ' --sql "select field1, field2, field3 from mytable" '.
  ' --include-result-metadata '.
  ' --output json';

exec($cmd, $output, $ret);
@=myGrid = [];
$rowNo = 0;

if (!empty($output)) {
   $aRows = json_decode($output, true);
   foreach ($aRows as $aRow) {
      $rowNo++;
      @=myGrid[ $rowNo ] = [ 
           'field1' => $aRow['field1'],
           'field2' => $aRow['field2'],
           'field3' => $aRow['field3']
      ];
   }
}
Then, a grid associated with the "myGrid" variable will display the contents of the query if the IDs of its fields are named "field1", "field2" and "field3".

This is the best that I can figure out without having AWS to test. You will probably have to debug the code that I gave you, since I'm just guessing from reading the documentation.

Modalert 200 MG is a brand name for the generic dr[…]

Fildena double 200 mg capacity to move the relaxin[…]

Wat is Fildena Double 200?

Fildena double 200 mg capacity to move the relaxin[…]

💥 Join the Exclusive Trading Community and Experie[…]