jersy opened a new issue, #5041:
URL: https://github.com/apache/kyuubi/issues/5041

   ### Code of Conduct
   
   - [X] I agree to follow this project's [Code of 
Conduct](https://www.apache.org/foundation/policies/conduct)
   
   
   ### Search before asking
   
   - [X] I have searched in the 
[issues](https://github.com/apache/kyuubi/issues?q=is%3Aissue) and found no 
similar issues.
   
   
   ### Describe the bug
   
   There is a table named test_student_02, which contains data of students who 
are around 18 years old. The "age" column has been hashed for data masking. 
When using the following SQL query, no data can be retrieved.
   
   
   var ds4 = spark.sql("select * from user02db.test_student_02 where age > 18");
   ds4.explain(true);
   
   
   'Project [*]
   +- 'Filter ('age > 18)
      +- 'UnresolvedRelation `user02db`.`test_student_02`
   
   == Analyzed Logical Plan ==
   id: int, name: string, sex: boolean, age: string, department: string
   Project [id#18, name#19, sex#23, age#24, department#22]
   +- Filter (cast(age#24 as int) > 18)
      +- SubqueryAlias `user02db`.`test_student_02`
         +- Filter (department#22 = IS)
            +- RowFilterMarker
               +- DataMaskingStage0Marker HiveTableRelation 
`user02db`.`test_student_02`, org.apache.hadoop.hive.ql.io.orc.OrcSerde, 
[id#18, name#19, sex#20, age#21, department#22]
                  +- Project [id#18, name#19, (0 = 0) AS sex#23, 
md5(cast(cast(age#21 as string) as binary)) AS age#24, department#22]
                     +- Relation[id#18,name#19,sex#20,age#21,department#22] orc
   
   == Optimized Logical Plan ==
   Project [id#18, name#19, true AS sex#23, md5(cast(cast(age#21 as string) as 
binary)) AS age#24, department#22]
   +- Filter ((isnotnull(department#22) && (department#22 = IS)) && 
(cast(md5(cast(cast(age#21 as string) as binary)) as int) > 18))
      +- Relation[id#18,name#19,sex#20,age#21,department#22] orc
   
   ### Affects Version(s)
   
   master
   
   ### Kyuubi Server Log Output
   
   _No response_
   
   ### Kyuubi Engine Log Output
   
   _No response_
   
   ### Kyuubi Server Configurations
   
   _No response_
   
   ### Kyuubi Engine Configurations
   
   _No response_
   
   ### Additional context
   
   _No response_
   
   ### Are you willing to submit PR?
   
   - [ ] Yes. I would be willing to submit a PR with guidance from the Kyuubi 
community to fix.
   - [ ] No. I cannot submit a PR at this time.


-- 
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]

Reply via email to