0

So our current setup has a channel with a playa field. This worked well so far BUT now we need to store specific values for each relationship (eg: The related field will need a catalogue number, specific price etc so each child relationship can have unique values as well).

From the top of my head this could be achieved by creating a new matrix/grid field in the same channel with all those unique columns (playa relationship field, catalogue number, price, etc).

My questions is, would that be the best solution for this issue? If so, I'm guessing that a MySQL query with the right format should do the job?

Cheers, Alberto

1

Correct - it'll have to be a Matrix field, as I believe that Playa is not compatible with the Grid.

You'll have to:

  • find all of the entries in exp_playa_relationships which use the old parent_field_id
  • change each row to the new parent_field_id
  • insert a new entry in exp_matrix_data with the correct entry_id and field_id
  • add the new parent_col_id and parent_row_id (which will be 0) to your existing exp_playa_relationships row
| improve this answer | |
  • 1
    Hi Derek. We've followed your approach and everything seems to be working that way. Thanks heaps! – marlavski Nov 6 '14 at 6:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.