how can I check if a column is equal to (empty string) when creating a custom event property?
Hi Elena M., Please stand by as I search the Mixpanel knowledge base for an AI-powered answer. I normally take about 15 seconds or so. In case AI cannot answer your question, feel free to reach out to Mixpanel support at mixpanel.com/get-support. If you have follow-up questions for this thread, please tag me again with your question: @kapa.ai <follow-up question> π
Feel free to ask a follow-up question once I've answered by mentioning me with @kapa.ai
You can compare directly to an empty string literal in the custom property formula.
For example, if your event property is called My Column, your custom event property formula would be:
``` text if(.["My Column"] == "", "is empty", "is not empty")
LBKSThe key points from the docs:
- Empty string means the property was sent as `""` and appears in the UI as `(empty string)`. [[Falsy values](https://docs.mixpanel.com/docs/data-structure/property-reference/data-type#falsy-values)]
- Custom properties support the `==` and `!=` comparison operators for strings. [[Comparison operators](https://docs.mixpanel.com/docs/features/custom-properties#comparison-operators)]
So anywhere in a custom property formula, use `== ""` to check βis equal to (empty string)β, or `!= ""` to exclude empty strings.
kapa.ai is still learning and improving, please let me know how I did by reacting below.
βΉοΈΒ Tip: Mention @kapa.ai in the thread for follow-ups or DM the app for 1-to-1 help.
