F
Filamentβ€’2w ago
lbar

Exporter duplicate rows for relations

Hi, i'm working with the exporter. I need to to duplicate the record of the table exported, one for every relation of the record (it's a registration->members relation so 1 registration with N members, with a pivot table). It's there a way to duplicate the exported record in that way? Example (pseudo code):
registration_id, registration_transaction_id, member_firstname, member_lastname
1, 123, john, doe
1, 123, jane, doe
2, 345, may, jane
2, 345, july, crockett
...
...
...
registration_id, registration_transaction_id, member_firstname, member_lastname
1, 123, john, doe
1, 123, jane, doe
2, 345, may, jane
2, 345, july, crockett
...
...
...
can't find anything online, and LLM goes crazy very bad with that one... πŸ˜• ty
1 Reply
lbar
lbarOPβ€’7d ago
ok maybe solved with a raw query with join. But to me looks pretty strange that is not possible (or at least i haven't found a way) to do it in a clean eloquent way...

Did you find this page helpful?