Bug 2254582

Summary: [rgw][s3select]: wrong output seen for query "select ( not 'Ix8vrSP6MNFNMnjLG0XB' ) from s3object;"
Product: [Red Hat Storage] Red Hat Ceph Storage Reporter: Hemanth Sai <hmaheswa>
Component: RGWAssignee: gal salomon <gsalomon>
Status: CLOSED ERRATA QA Contact: Hemanth Sai <hmaheswa>
Severity: high Docs Contact:
Priority: unspecified    
Version: 7.0CC: akraj, ceph-eng-bugs, cephqe-warriors, gsalomon, mbenjamin, mkasturi, tserlin
Target Milestone: ---Keywords: Automation
Target Release: 7.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: ceph-18.2.1-119.el9cp Doc Type: Bug Fix
Doc Text:
.SQL statements containing boolean expression return boolean types Previously, SQL statements containing boolean expression (a projection) would return a string type instead of boolean type. With this fix, the engine identifies a string as a boolean expression, according to the statement syntax, and the engine successfully returns a boolean type (true/false).
Story Points: ---
Clone Of: Environment:
Last Closed: 2024-06-13 14:18:44 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Hemanth Sai 2023-12-14 17:05:12 UTC
Description of problem:
not operator on string in the select clause is returning the same string instead of boolean value 

executing query-65: select ( not 'Ix8vrSP6MNFNMnjLG0XB' ) from s3object;
Stats
{'Details': {'BytesProcessed': 145,
             'BytesReturned': 63,
             'BytesScanned': 145}}
End
{}
Ix8vrSP6MNFNMnjLG0XB
Ix8vrSP6MNFNMnjLG0XB
Ix8vrSP6MNFNMnjLG0XB



Version-Release number of selected component (if applicable):
ceph version 18.2.0-128.el9cp

How reproducible:
always

Steps to Reproduce:
1.deploy rhcs7.0 cluster with rgw daemon
2.upload an s3select object
3.execute the above query and verify the results are correct

Actual results:
not operator on string in the select clause is returning the same string instead of boolean value 

Expected results:
expected boolean value as result

Additional info:
query result validation script: https://docs.google.com/document/d/1UT8zTizHHVTWYmfXZdgChYJh7rT4bovOJmsecS86qYU/edit?usp=sharing

Comment 1 gal salomon 2024-03-25 12:45:07 UTC
fix at https://github.com/ceph/ceph/pull/56279

Comment 6 errata-xmlrpc 2024-06-13 14:18:44 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Critical: Red Hat Ceph Storage 7.1 security, enhancements, and bug fix update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2024:3925

Comment 7 Red Hat Bugzilla 2024-10-12 04:25:14 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 120 days