I think we need a good example of date range searching. To this end, we probably need a dataset we can add that uses our new types.
// Find a user who has an activation_id matching activationID and who has // an activation_created_at within the last day, and return the ID(s) Vs, _ := cayley.StartPath(db.QuadStore). Has(quad.IRI("is_a"), quad.String("user")). Has(quad.IRI("activation_id"), quad.String(activationID)). Tag("id"). Out(quad.IRI("activation_created_at")). Filter(iterator.CompareGT, quad.Time(time.Now().AddDate(0, 0, -1))). // <- actual date filter. Back("id"). Iterate(nil).AllValues(nil)
I have a strange feeling I can understand ‘path walking’.
Tell me if I understand the above: you start with all nodes but filter them to only keep those that are users and have specific activation id. Than you walk out and reach all the activation creation date nodes and filter in such a way that you only keep those nodes that are from a specific date. Than you walk back to the previous nodes and print them.
I feel like you might print too many nose and not just the greater than a date since you tagged a bit early buy I probably don’t understand it completely.
You get it mostly. When you go “Back” to a tag, it goes back along the still active paths, so those filtered out are removed, but you got the rest right.
Thanks. btw, what’s RFR? Request for responses? or maybe resources?
It was Request For Recipe – now RFHT.
Is there a GIZMO equivalent of this ?