csun5285 commented on code in PR #70408:
URL: https://github.com/apache/doris/pull/70408#discussion_r4749515828


##########
fe/fe-core/src/main/java/org/apache/doris/common/util/PropertyAnalyzer.java:
##########
@@ -2391,19 +2393,19 @@ public static int 
analyzeVariantMaxSubcolumnsCount(Map<String, String> propertie
         return maxSubcoumnsCount;
     }
 
+    // variant_enable_typed_paths_to_sparse is internal now: accepted and 
ignored so that DDL printed by
+    // older versions (which emitted "variant_enable_typed_paths_to_sparse" = 
"false") and persisted SQL
+    // still parse, while new columns take the value from 
debug_variant_enable_typed_paths_to_sparse.
     public static boolean analyzeEnableTypedPathsToSparse(Map<String, String> 
properties,
                         boolean defaultValue) throws AnalysisException {
-        boolean enableTypedPathsToSparse = defaultValue;
         if (properties != null && 
properties.containsKey(PROPERTIES_VARIANT_ENABLE_TYPED_PATHS_TO_SPARSE)) {
-            String enableTypedPathsToSparseStr = 
properties.get(PROPERTIES_VARIANT_ENABLE_TYPED_PATHS_TO_SPARSE);
-            try {
-                enableTypedPathsToSparse = 
Boolean.parseBoolean(enableTypedPathsToSparseStr);
-            } catch (Exception e) {
-                throw new 
AnalysisException("variant_enable_typed_paths_to_sparse must be `true` or 
`false`");
+            String value = 
properties.get(PROPERTIES_VARIANT_ENABLE_TYPED_PATHS_TO_SPARSE);
+            if (!"true".equalsIgnoreCase(value) && 
!"false".equalsIgnoreCase(value)) {
+                throw new 
AnalysisException("variant_enable_typed_paths_to_sparse must be  or ");

Review Comment:
   Fixed the error message in eabace67349. 
   Silently ignoring both "true" and "false" (like 
variant_sparse_hash_shard_count) is intentional 
   I'll open a follow-up doc PR to update #4658 accordingly.



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