Arnab Karmakar has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/23566 )

Change subject: IMPALA-14065: Support WHERE clause in SHOW PARTITIONS statement
......................................................................


Patch Set 8:

(1 comment)

http://gerrit.cloudera.org:8080/#/c/23566/8/fe/src/main/java/org/apache/impala/analysis/PartitionPredicateEvaluator.java
File 
fe/src/main/java/org/apache/impala/analysis/PartitionPredicateEvaluator.java:

http://gerrit.cloudera.org:8080/#/c/23566/8/fe/src/main/java/org/apache/impala/analysis/PartitionPredicateEvaluator.java@77
PS8, Line 77:     // Rewrite rand()/random() without arguments to use partition 
ID as seed.
1. We are using seeding here, as we want to execute the rand() function for 
each partition individually.
2. rand() always produces the same value with the same seed, so in order to 
bring randomness Ive fed the partitionId as seed. This is deterministic as 
partitionIds dont change unless metadata is invalidated.
https://impala.apache.org/docs/build/html/topics/impala_math_functions.html#math_functions__rand



--
To view, visit http://gerrit.cloudera.org:8080/23566
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2e2a14aabcea3fb17083d4ad6f87b7861113f89e
Gerrit-Change-Number: 23566
Gerrit-PatchSet: 8
Gerrit-Owner: Arnab Karmakar <[email protected]>
Gerrit-Reviewer: Arnab Karmakar <[email protected]>
Gerrit-Reviewer: Impala Public Jenkins <[email protected]>
Gerrit-Reviewer: Michael Smith <[email protected]>
Gerrit-Reviewer: Pranav Lodha <[email protected]>
Gerrit-Reviewer: Quanlong Huang <[email protected]>
Gerrit-Reviewer: Riza Suminto <[email protected]>
Gerrit-Reviewer: Surya Hebbar <[email protected]>
Gerrit-Comment-Date: Wed, 19 Nov 2025 18:26:36 +0000
Gerrit-HasComments: Yes

Reply via email to