Oracle icon

Oracle

Executa consultas SQL no banco de dados Oracle

Atualizar

AI-generated

Overview

This node enables executing SQL operations on an Oracle database. It supports running arbitrary SQL queries as well as common data manipulation operations such as inserting, updating, and deleting rows in specified tables.

Typical use cases include:

  • Automating database updates or inserts based on workflow data.
  • Running custom SQL queries to fetch or manipulate data.
  • Deleting records conditionally from a table.
  • Integrating Oracle database operations into larger automation workflows.

For example, you could update customer records where the customer ID matches a certain value, insert new product entries, or delete obsolete records automatically.

Properties

Name Meaning
Tabela The name of the target table for insert, update, or delete operations.
Colunas / Valores Columns and their corresponding values to be inserted or updated. Multiple column-value pairs allowed.
Condição WHERE The SQL WHERE clause condition (without the "WHERE" keyword) to filter rows for update or delete operations.
Opções Adicionais Additional options including:
- Tamanho Máximo De Linhas: Maximum number of rows to return.
- Converter Datas ISO: Whether to convert date fields to ISO string format.
- Commit Automático: Whether to automatically commit changes after the operation.

Output

The output JSON contains either:

  • rows: An array of objects representing the resulting rows from a query or affected rows from insert/update/delete operations. If the "Converter Datas ISO" option is enabled, any Date fields are converted to ISO 8601 strings.
  • rowCount: The count of rows returned by a query.
  • rowsAffected: The number of rows affected by insert, update, or delete operations.

No binary data output is produced by this node.

Dependencies

  • Requires an Oracle database connection with appropriate credentials (username, password, and connection details).
  • Uses the official OracleDB Node.js driver (oracledb package).
  • Needs proper configuration of connection parameters such as host, port, and connection method (e.g., TNS, SID, or service name).
  • Requires an API key credential or equivalent authentication token configured in n8n for connecting to the Oracle database.

Troubleshooting

  • Connection errors: Ensure that the Oracle database is reachable from the n8n instance and that credentials are correct.
  • SQL syntax errors: Verify that the SQL statements, especially the WHERE clause, are correctly formed without the "WHERE" keyword included in the input.
  • Empty results or no rows affected: Check that the WHERE clause matches existing rows; otherwise, no rows will be updated or deleted.
  • Commit issues: If changes do not persist, verify that the "Commit Automático" option is enabled or handle commits manually if disabled.
  • Date conversion problems: If dates are not formatted as expected, toggle the "Converter Datas ISO" option accordingly.

Common error messages typically relate to invalid SQL syntax, missing table names, or connection/authentication failures. Reviewing the exact error message and verifying inputs usually resolves these issues.

Links and References

Discussion