You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@superset.apache.org by GitBox <gi...@apache.org> on 2018/02/06 17:04:32 UTC

[GitHub] xrmx commented on a change in pull request #4358: [druid] fix bug around handling NULLs

xrmx commented on a change in pull request #4358: [druid] fix bug around handling NULLs
URL: https://github.com/apache/incubator-superset/pull/4358#discussion_r166372483
 
 

 ##########
 File path: superset/viz.py
 ##########
 @@ -68,19 +68,22 @@ def __init__(self, datasource, form_data):
         self.status = None
         self.error_message = None
 
-    def get_fillna_for_type(self, col_type):
+    def get_fillna_for_col(self, col):
         """Returns the value for use as filler for a specific Column.type"""
-        if col_type:
-            if col_type == 'TEXT' or col_type.startswith('VARCHAR'):
-                return ' NULL'
+        if col:
+            if col.is_string:
+                return 'NULL'
 
 Review comment:
   The space was done on purpose for having NULL entries before other values after sorting

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services