Doris-Breakwater commented on issue #70913: URL: https://github.com/apache/doris/issues/70913#issuecomment-7121058475
Confirmed from source at `59de8c4c524` and `6e66809`. This is an FE regression in `SHOW TRANSACTION` predicate validation. Nereids parses both `'visible'` and `'VISIBLE'` as `VarcharLiteral`. The `STATUS` branch requires `StringLiteral`, so validation rejects both before it can normalize the value or call the transaction manager. The shared-nothing manager already filters the database’s transaction states by the requested enum. [Literal parsing](https://github.com/apache/doris/blob/59de8c4c524/fe/fe-core/src/main/java/org/apache/doris/nereids/parser/LogicalPlanBuilder.java#L3553-L3570) · [Command validation](https://github.com/apache/doris/blob/59de8c4c524/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/commands/ShowTransactionCommand.java#L126-L156) · [Status lookup](https://github.com/apache/doris/blob/59de8c4c524/fe/fe-core/src/main/java/org/apache/doris/transaction/DatabaseTransactionMgr.java#L269-L289) The mismatch was introduced by the Nereids migration and is present in the `4.0.0-rc01` source. The legacy `2.1.9-rc02` path uses the string literal type that its analyzer expects. Cloud mode has an explicit unsupported-operation error in its status lookup. [Nereids migration #50695](https://github.com/apache/doris/pull/50695) · [Legacy analyzer](https://github.com/apache/doris/blob/2.1.9-rc02/fe/fe-core/src/main/java/org/apache/doris/analysis/ShowTransactionStmt.java#L122-L135) · [Cloud status lookup](https://github.com/apache/doris/blob/59de8c4c524/fe/fe-core/src/main/java/org/apache/doris/cloud/transaction/CloudGlobalTransactionMgr.java#L2472-L2475) For the PR, accept `StringLikeLiteral` for `STATUS = ...` and retain case-insensitive enum validation. Keep the status predicate restricted to equality, since the initial expression check also admits `LIKE`. Add a shared-nothing SQL regression that first confirms the inserted transaction is `VISIBLE` via its label, then checks that both case variants return that transaction. Include an invalid status case. The current unit test constructs a `StringLiteral` directly, and the SQL regression exercises label filters only. [Unit test](https://github.com/apache/doris/blob/59de8c4c524/fe/fe-core/src/test/java/org/apache/doris/nereids/trees/plans/commands/ShowTransactionCommandTest.java#L82-L92) · [SQL regression](https://github.com/apache/doris/blob/59de8c4c524/regression-test/suites/query_p0/show/test_show_transaction.groovy#L36-L44) The supplied build, deployment mode, SQL, and error are sufficient for triage. The remaining validation is a before-and-after run of the SQL regression on shared-nothing and confirmation of which maintained branches need the backport. To look up a known transaction in the meantime, use its label or ID and read the `TransactionStatus` column. Breakwater-GitHub-Analysis-Slot: slot_3787bbeafd46 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
