Skip to main content
Question

Targeting Rules conditions with integers or dates?


Forum|alt.badge.img+4

Hi,

Currently, the SDK for Unity only allows string values to be sent for customer attributes.

Also, in the Targeting Ruels UI, it seems to only do string comparisons.

Am I doing something wrong, or is it limited to strings only?

thanks!

3 replies

alejandra-wetsch
RevenueCat Staff
Forum|alt.badge.img+2

Hey ​@DoughBoy

Thank you for reaching out, I’ll be happy to help! 

You're not doing anything wrong! As you mentioned, the SDK currently only accepts Strings for user attribution. So, in your case, to target a specific user by date or integer, you should parse the date or integer, assign it as a String, and pass it along to the SDK. The only thing to consider here is that you should always respect the same format for dates in the dashboard and your code, for the targeting to work as expected.

Please let us know if you have any questions or if we can help in any other way! 
Best, 


Forum|alt.badge.img+4
  • Author
  • Member
  • 5 replies
  • July 12, 2025

hi ​@alejandra-wetsch ,

 

thanks for the reply.

Are you saying that there’s no way to do comparisons, and its only equality (is any of, or not any of..) operations?

For example, what if I want a targeting rule if the users age is over 50?

What if I want a targeting rule if the sign up date is more than 7 days ago?

thanks!


alejandra-wetsch
RevenueCat Staff
Forum|alt.badge.img+2

Hey ​@DoughBoy

Thank you for following-up! 

That’s correct! As of right now, comparisons are not supported. You can only include attributes with is any of or exclude them with is not any of

Please let us know if you have any questions or if we can help in any other way! 
Best,


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings