Alex1888 commented on code in PR #45582:
URL: https://github.com/apache/doris/pull/45582#discussion_r1889698307


##########
fe/fe-core/src/main/java/org/apache/doris/analysis/ColumnDef.java:
##########
@@ -600,7 +590,21 @@ public String toSql() {
         }
 
         if (defaultValue.isSet) {
-            sb.append(defaultValue.toSql()).append(" ");
+            if (defaultValue.value != null) {
+                if (typeDef.getType().getPrimitiveType() != 
PrimitiveType.BITMAP

Review Comment:
   nested if is not a good pattern here. try to use 
   ```
   if (defaultValue.value = null){
   }
   eles if(typeDef.getType().getPrimitiveType() == PrimitiveType.BITMAP) {
   }
   
   ```



-- 
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: commits-unsubscr...@doris.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to