Show latest event using timestamp

I have 2 tables A & B with 1-many relationship.

I created 2 views:

  1. A.view.lkml
  2. B.view.lkml

In models, I joined them:

explore: A {
  join: B  {
     relationship: one_to_many
     sql_on: ${A.receipt_id} = ${B.receipt_id} ;;
  }
}

I would like to show all data from table A and latest B.event using B.event_timestamp

But I am not sure how to do that. I get duplicated events in the table, but I only want to show the latest event.

Can someone shed some light?

0 1 199
1 REPLY 1
Top Labels in this Space