Skip to content

[Bug]: Action Truncate tables reports success (result=[true]) on missing connection or execution failure #8777

Closed

Description

@samuelwillyanto1

Apache Hop version?

2.20.0-SNAPSHOT

Java version?

21

Operating system

Windows

What happened?

Description

  1. False Positive Result on Error:
    When Action Truncate tables encounters an error (such as when no database connection is selected, or a database connection fails to connect), it logs an error but still completes with result=[true]. Because nrErrors is 0 and never incremented in the catch block (updateErrors() was not called), nrErrors == 0 evaluates to true at the end of execute(), overwriting the error status and causing the workflow to report SUCCESS.

  2. Missing Schema Population in Dialog:
    In ActionTruncateTablesDialog, clicking "Click here to return tables name list" only populates table names and leaves the Schema name column blank. For databases with multiple schemas, users have to manually type schema names. Additionally, clicking it when no connection is selected throws an unhandled error rather than showing a user-friendly dialog.

  3. Missing Workflow Verification for Tables:
    The action did not implement the check(...) method to warn users during Verify Workflow (F7) when no tables are selected to truncate.

Steps to Reproduce

  1. Create a workflow and add a "Truncate tables" action.
  2. Leave the "Connection" field empty and enter a table name in the table grid.
  3. Run the workflow.
  4. As shown in the screenshot, the action logs an error, but finishes with "result=[true]" and proceeds along the success hop.
Image

Expected Behavior

  • The action should call updateErrors() on connection or execution failures so result=[false] and nrErrors > 0.
  • The dialog should validate connection before fetching table names and populate both Table name and Schema name automatically.
  • Verify Workflow (F7) should warn when no tables are selected.

Issue Priority

Priority: 2

Issue Component

Component: Actions, Component: Database, Component: Hop Gui

Activity

  1. samuelwillyanto1 commented on Oct 7, 2026

    @samuelwillyanto1
    ContributorAuthor

    .take-issue

  2. added this to the 2.20 milestone on Oct 7, 2026
  3. added 2 commits that reference this issue on Oct 9, 2026
  4. added a commit that references this issue on Oct 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions