What kind of relationship is âParticipationsâ in your ActiveRecord compaign model definition?
Is it a has_many or a many to many relationship?
In other words, are you sure that the 269 participations are unique in terms of influencer?
Hi @arnaud! campaign has_many :participations and participation belongs_to :influencer.
Yes I am sure the 269 participations are unique in terms of influencer_id. To further illustrate the case, Iâv added the participations.id.
Can we do another test to have more insights about the issue?
Could you try to export those 269 participations using the âExport participationsâ action in the âActionsâ dropdown?
Then if it would be great to confirm that the exported CSV file does not contain duplicate influencers.
I have 2 other questions:
Do you have the same issue if you order by the id column (and not the state one)?
Do you observe this issue only with this relationship in your project?
I confirm the CSV does not contain any duplicates, I have exactly 269 unique records
I donât have the same issue when ordering on id. The problem occurs with the state field (enum type)
Itâs difficult to say, if I observe the issue only on this relationship. Others does not necessssarly require pagination. Currently, it is really on this view and it is quite cumbersome as itâs a main admin view.
There is actually a problem on Forest Admin side, probably due to order by and limit usage with pagination, on non-unique fields. We have to fix it, I opened an issue. Be sure you will be notified as soon as it is resolved. As a workaround, for now, you could try to use search, export, and sorting by ID features. Thank you for your patience and your help in understanding the bug.