Batching queries in to one transaction

I keep getting issues acquiring deadlock EER_LOCK_DEADLOCK: Deadlock found when trying to get lock; try restarting transaction. Im having to run a bunch of query.trigger() in a Javascript function. But I keep getting this deadlock issue. Is there a good way to get around this?

Hey there! What kind of query is that .trigger() running? Whether the resource supports any kind of batch or bulk actions is going to depend on both the resource and whether our integration supports bulk actions

They are running mysql queries. Im running them in Promises like so:
They are update queries.

   return copyLatestClaim.trigger({
     additionalScope: {
             "claim_id": row.claim_id

What do the individual queries look like here? You can do bulk queries of almost any type possible in the RAW SQL mode of the mysql query editor, or you can use the structured bulk insert, bulk update, or bulk upsert options inside of GUI mode:

For bulk upserts or updates, the input is expecting an array of objects like this:
[ { "id": 1, "name": "my new name"}, { "id": 2, "name": "your new name"} ]

For an insert, it shouldn’t need the primary key of the table since that is typically generated when a new record is created