Aerospike is primarily a key-value store, so this isn’t something you would want to do regularly or expecting good performance. One way to work around this is by indexing on the fly, as Piyush explained here One to many relationship with filter - #6 by pgupta. You could also accomplish a regex/wildcard match across all the data using predicate filtering, https://www.aerospike.com/docs/guide/predicate.html, but it is very heavy on the system and you might should explore alternatives first.
Can we know more about your use case?