Join with wildcard keys

Hello,

In my system I have millions of documents that have events that a user has done. The keys are in the format event::user::datelikestring

key: event::105::20170102AA
{
“something” : 28
“user” : 105
}

key: event::105::20161230CD
{
“something” : 78
“user” : 105
}

key: event::106::20170108ZY
{
“something” : 45
“user” : 106
}

I want to join to these documents on their key, but would need to wildcard out the datelikestring at the end.

JOIN devbucket ON KEYS “event::105::%”

Is something like that possible?

Try a subquery:

JOIN devbucket ON KEYS ( SELECT RAW ... )

1 Like

Fantastic, thank you.

Worked like magic.

1 Like

Worked like yebomagic.

2 Likes