https://www.growthbook.io/ logo
#ask-questions
Title
# ask-questions
p

purple-winter-48671

02/29/2024, 2:14 AM
I'm hoping to use two attributes for targeting, but one attribute has two potential scenarios: being false or NULL so need to do both an OR and an AND... and I can't quite get it working. Had a hunt here and online and I've got the following, but it needs tweaking, any advice?
Copy code
{
  "$and": [
    {"$or":[
        {"or_feature_name": 
    {"$eq": false}, {"$exists": false}}
    ],
    },
    {"and_feature": "nz",}
  ]
}
f

fresh-football-47124

02/29/2024, 5:07 AM
Why not fix it on the SDK side to force the Attribute into a more consistent state?
p

purple-winter-48671

03/04/2024, 9:10 PM
I'm hoping to minimise the dev effort required (and some of our older customers won't hit the screens that set the attribute until they've updated the app). Does this mean it's not possible? Or just that it isn't preferrable?
8 Views