Skip to content

ADD coalesce function #3137

@MPizzotti

Description

@MPizzotti

Feature Request

i'd like to have a new function called coalesce just like the SQL variant.

Description of Problem:

it could happen that a dataset has empty values and we want to insert a default.
currently is possibile... but by manually declaring IF conditions:
if(is_not_null("column_name")){"column_name"}else{'default_value'}

Potential Solutions:

implement a new function, called coalesce, that works just like his corresponding SQL variant, (also by chaining values/using arrays):
coalesce("column_name", 'default')
coalesce("column_name1", "column_name2", "column_name3", 'default') / coalesce(["column_name1", "column_name2", "column_name3"], 'default')

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementFeature requests or improvements

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions