Skip to main content

Abort Query

This action stops an in-flight query, one that was triggered via Run or Preview and is still waiting for a response, when an event occurs.

Configuration

ParameterDescriptionDefault
QueryThe query to abort
DebounceTime in milliseconds to wait before executing the actionEmpty (no delay)
ToolJet - Action reference -  Abort Query

Behavior

  • Abort only cancels the pending request on the client. If the data source (for example, a database) has already started processing the query, it may continue running on its end until it completes on its own.
  • Abort is not available for RunJS, RunPy, and Workflow queries, since these don't execute as cancellable network requests.

Triggering via RunJS

queries.<queryName>.abort();

or

await actions.abortQuery('<queryName>');
info

For a full quick-reference of all actions' RunJS syntax, see Run Actions from RunJS.