Skip to main content

Error Executing SQL Command

Error Executing SQL Command explained on the SQL server.

Praise Magidi avatar
Written by Praise Magidi
Updated over 2 months ago

Message

Error executing SQL command: Connection closed before request completed (ECLOSE).

Cause

The error "Connection closed before request completed" occurs when the database server actively terminates the connection while a query is still in progress. This typically happens when:

  • The SQL Server shuts down/restarts.

  • The SQL Server instance reaches resource limits and cuts servers connections.

  • Max connection time exceeded.

Resolution

  • Restart the flow.

  • Increase timeout on the step to an appropriate value for the query.

  • Check the configured server timeout and increase it an appropriate value for the query if necessary.

  • Avoid running flows during maintenance periods/windows.

  • Check if the database is under heavy load and optimize queries or upgrade hardware if necessary.

Error Detail

{
"message": "Error executing sql command",
"statusCode": 400,
"errorMessage": "Connection closed before request completed.",
"error": {
"message": "Connection closed before request completed.",
"code": "ECLOSE"
},
"stepType": "Destination",
"stepName": "Buffer",
"stepId": "931xxxx6-exxxx-4xxx1-xxxxx-xxxxxxxxxx",
"mapStepId": "-mVhCjiWw",
"mapStepPath": "-mVhCjiWw",
"mapStepType": "Step",
"module": "Synatic",
"commandProcessingError": null
}

Did this answer your question?