mirror of
https://github.com/apache/superset.git
synced 2024-09-12 00:29:39 -04:00
[bugfix] IS NOT NULL filter triggers KeyError: 'val' (#5764)
This commit is contained in:
parent
ba4b8a033b
commit
6c6ea3730b
@ -724,13 +724,13 @@ def to_adhoc(filt, expressionType='SIMPLE', clause='where'):
|
||||
|
||||
if expressionType == 'SIMPLE':
|
||||
result.update({
|
||||
'comparator': filt['val'],
|
||||
'operator': filt['op'],
|
||||
'subject': filt['col'],
|
||||
'comparator': filt.get('val'),
|
||||
'operator': filt.get('op'),
|
||||
'subject': filt.get('col'),
|
||||
})
|
||||
elif expressionType == 'SQL':
|
||||
result.update({
|
||||
'sqlExpression': filt[clause],
|
||||
'sqlExpression': filt.get(clause),
|
||||
})
|
||||
|
||||
return result
|
||||
|
Loading…
Reference in New Issue
Block a user