"duplicate" records

prophoto

Active Member
In my lis site, list #2, records are showing duplicates in the div view. Suggestions? When I check them in phpmyadmin the records are not duplicated but in the frontend of fabrik they are. Help please, thanks!
 
I assume you have a list with a join and display mode is not set to 'merge rows'.

gesendet mit Tapatalk
 
All it does is change the way the list is displayed, it doesn't affect your data at all.

Helps if you understand the whys and wherefores. Remember that when you have a "many" relationship in a relational database, where the 'parent' table can have multiple 'child' rows in the related table, and you select that parent using a 'join' to the child, like this ...

SELECT * FROM parent LEFT JOIN child ON parent.id = child.parent_id

... if you have (say) three rows in 'child' which all have the same 'parent' (in Fabrik terms, you have 3 repeats of that child group), then you get back three rows from the select. The rows in the selection will share the same parent row data, but have different child data, like ...

parent.id, parent.moms_name, parent.dads_name, child.id, child.childs_name

1,Jane Smith, John Smith, 1, Little Bobbie Smith
1,Jane Smith, John Smith, 2, Mary Jo Smith
1,Jane Smith, John Smith, 3, Chuck Smith

So ... how should that be handled when it comes to displaying your data in a List?

If you have "Individual rows" selected in your join settings, the above is what your list will look like. Three seperate rows, one for each "repeat" in the result set, with the data from the 'parent' repeated.

If you select "merge", then we'll take that repeated data, and reduce it down to a single row, with the repeated data shoe-horned in to a single table cell for each column ...

Code:
1, Jane Smith, John Smith, 1, Little Bobbie 
                          2, Mary Joe Smith
                          3, Chuck Smith

It's safe to play with - like I said, it doesn't change anything except how the list is displayed, nothing is changed in your data.

-- hugh
 
Oh, and the different between 'merge' and 'merge and reduce' is to do with when you have multiple repeat joins, you won't see any difference between the two options if you only have one repeat join.

-- hugh
 
Thanks for the education! The more the merrier. One thing I don't understand is why my records are being duplicated on my list #2, not the target dropdown. Changing this helped , but I still have some duplicates. On the list page for list #2 you can see two duplicates at the top.
 
Even with merge rows you can get 'duplicates' if you are ordering ny one of your child elements. Select an element of your main table as first 'order by' in list settings to force correct merging.

gesendet mit Tapatalk
 
We are in need of some funding.
More details.

Thank you.

Members online

No members online now.
Back
Top