Actions7
Overview
This node allows executing SQL queries directly against a database connected to SAP Business One or interacting with SAP Business One via its Service Layer through a Unified MCP Server. Specifically, for the Query resource and Execute Query operation, it supports running arbitrary SQL queries on the database connection.
Common scenarios include:
- Retrieving data from SAP Business One tables using custom SQL queries.
- Running parameterized queries to filter or aggregate business data.
- Integrating complex reporting or data extraction workflows that require direct database access.
For example, you might use this node to run a query like SELECT * FROM OCRD WHERE CardCode = @cardCode
with parameters { "cardCode": "C20000" }
to fetch details of a specific business partner.
Properties
Name | Meaning |
---|---|
Connection Type | Type of connection to use: - Direct Database (runs SQL queries directly) - Service Layer (not applicable for Execute Query) |
SQL Query | The SQL query string to execute. Must be provided when using Direct Database connection. |
Query Parameters | JSON object representing parameters for the SQL query, allowing safe parameterization. |
Output
The node outputs an array of items where each item contains a json
property holding the result of the executed SQL query. The structure of the json
output depends on the query but typically includes rows returned by the query as objects with column names as keys.
If the query returns no results, the output will be an empty array.
The node does not output binary data for this operation.
Dependencies
- Requires a valid connection to the Unified MCP Server configured with an API URL and authentication credentials (an API key credential).
- For the Direct Database connection type, the MCP Server must support direct SQL query execution.
- No additional environment variables are required beyond the configured credentials.
Troubleshooting
- Invalid SQL syntax error: Ensure your SQL query is correctly formatted and valid for the target database.
- Missing or incorrect query parameters: If your query uses parameters, ensure the JSON object matches the placeholders in the SQL query.
- Connection errors: Verify the MCP Server URL and credentials are correct and that the server is reachable.
- Permission denied: The API user must have sufficient permissions to execute queries on the database.
- Empty results: Confirm that the query and parameters actually match existing data.
If the node throws an error, enabling "Continue On Fail" can help process multiple inputs without stopping the workflow.
Links and References
- SAP Business One Service Layer Documentation
- Unified MCP Server API Reference (replace with actual link if available)