MaxGekk commented on code in PR #37065:
URL: https://github.com/apache/spark/pull/37065#discussion_r917783468


##########
sql/catalyst/src/main/scala/org/apache/spark/sql/errors/QueryExecutionErrors.scala:
##########
@@ -878,9 +878,10 @@ private[sql] object QueryExecutionErrors extends 
QueryErrorsBase {
     new Exception(s"Unsupported type: ${dataType.catalogString}")
   }
 
-  def useDictionaryEncodingWhenDictionaryOverflowError(): Throwable = {
-    new IllegalStateException(

Review Comment:
   ... then no need to assign any error class to it.



##########
sql/core/src/main/scala/org/apache/spark/sql/execution/columnar/compression/compressionSchemes.scala:
##########
@@ -421,7 +421,7 @@ private[columnar] case object DictionaryEncoding extends 
CompressionScheme {
 
     override def compress(from: ByteBuffer, to: ByteBuffer): ByteBuffer = {
       if (overflow) {

Review Comment:
   If users never face to it, let's replace it by an assert. But I guess users 
might face to the restriction:
   ```scala
     // 32K unique values allowed
     val MAX_DICT_SIZE = Short.MaxValue
   ```
   @goutam-git Could you try to create big enough dictionary?



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