customRanking attribute is empty but result is at the top

We are using sales data to create a customRanking attribute that reflects relative sales of a product over the past week (higher number is better). Brand new products may have no sales data for a day or two. We have noticed in that case that those products get ranked at the top! Is that by design? Should we then always populate that attribute with something (e.g. “0”)?

Thanks in advance for any help!

Hi @jgraf - Sounds like an interesting scenario and we may need a bit more information to help.

Can you share with us:

  • What your “Indices” > “Configuration” > “Ranking and Sorting” looks like so we see your order of tie-breaking criterion (maybe you’re using the default, maybe not!)
  • What you “Custom Ranking” criterion looks like
  • Sample records, just a few such as what an “Existing Product” JSON object looks like and what a “New Product” (with no sales data) JSON object looks like

Thanks!