Parent and Child reUnion
I currently have a need to create a UNION between some Parent and Child records. The fields I want to use are mappable between the 2 tables, so the resulting selections can match.
In fact I have each selection in their own formula field for convenience, so array(children,parents) as the basis of a View field produces a list with the correct number of records (2 parents and 7 children), but although I can easily edit fields to show in the View, only data for the children is actually shown. I cannot get any parent field data to appear in the View - except one field.
These are actually motorcycles and both tables have fields for image, Make, Model and Name, named the same in both tables, but only the Name column in the View shows the data for all records. No matter how I try to select the appropriate field for the parent record, it remains blank - except the Name column which has data from both tables, i.e. for all records and which means using the same fieldname in both tables cannot be the problem.
To clarify, no these table cannot be merged, they are different actual data items. The parent is the model type and children are actual vehicles. I'm trying to view selected vehicles (children) plus some Models (parents) that have no children (vehicles), so no relationships involved between any of the selected records.
In the meantime I simply have 2 Views on the Form, one for the children and one for the parents, but I'd prefer to show all the data in a single View.
Any suggestions?
6 replies
-
If you are trying to make a new table that is a mix of the parent and child tables then you have to make a new JSON table or actually make a new table.
View elements can only take data from one table at a time, so if you want to mix tables then you will have to make use of HTML tables and JSON.
If you post a sample DB, we can help you out.
Content aside
- 6 days agoLast active
- 6Replies
- 51Views
-
4
Following
