Is there a way to set up a query entity to filter on fields that are an empty st

Certified Senior Developer
Is there a way to set up a query entity to filter on fields that are an empty string?

The following returns an error:

a!queryFilter(
field: "FIELDNAME",
operator: "<>",
value: ""
),

However, operator: "is null" seems to exclude the results that are "".

This is especially an issue because Appian will write an "" to a varchar field when a null is passed into a Write to Datastore entity. Now there is no way to query for these rows.

OriginalPostID-142029

OriginalPostID-142029

  Discussion posts and replies are publicly visible

Parents
  • Hi jason!
    If you run a null check by using isnull("") , it will run correctly. However for more functionality, you have to make a utility rule for cases where isnull might fail. You can make a rule named "CheckIsNull" with the following syntax:

    if(ri!List ="",true(),if(isnull(ri!List),true(),if(length(ri!List) > 0,false(),true())))

    where "List" is of Any type.
Reply
  • Hi jason!
    If you run a null check by using isnull("") , it will run correctly. However for more functionality, you have to make a utility rule for cases where isnull might fail. You can make a rule named "CheckIsNull" with the following syntax:

    if(ri!List ="",true(),if(isnull(ri!List),true(),if(length(ri!List) > 0,false(),true())))

    where "List" is of Any type.
Children
No Data