In Figure 1, the primary “Recipe Listing” table is related to other tables (such as Recipe Steps). Is it correct to reference these other tables as “List of xxxx”, or should they be referenced as a single entry (xxxxx)?
In Figure 2, the “Recipe Steps” table is shown. Each field contains a data array. Do I need to add a separate unique key field to link the two tables? Or, is it configured correctly using the Recipe Listing field?
The data in the “Recipe Steps” table will only be uploaded via a CSV file import (i.e. there will be no “add data” option within the app). When importing the CSV file (Figure 3), if I choose the Type of Data field as “Recipe Steps”, I can validate and upload the data. If, however, I choose the Type of Data as “Recipe Listing” (as shown in Figure 3), I get an error (“The field Steps has been used twice. Please check your settings”). Is this error linked to an incorrect database configuration?
Would seem fine, that looks like a good way to do it. You have also linked back from the listing step to the recipe (assumption is that a step is only relevant for a single recipe listing) which can be helpful. You might also want a list on the equipment and ingredient tables as well, as that can make life easier at times. But it does depend on what you are trying to do.
I think this one will get complicated, I would suggest that having the multiple arrays isn’t what you want. You want a single “step” thing that has the step number and text rather than in two arrays. That way you can simply list out all recipe listing steps ordered by step number. You probably don’t want to have unique ids linking things, embeding (as you have done) is far far easier in almost all cases.
You will need to have two different loads, one loads the recipe listing, the next loads the steps and links to the recipe. Not done one of these for a while, but you then might need to run a Bulk API to create the list of steps on the main Recipe Listing.
As I often say, rather than think about how to “store” the data, it is often helpful to think about how you want to access it. Then see if your structure supports that in a simple way. You spend far more time building queries for data than you do creating it.
In the Recipe Listing data type, the “ID” field is the unique identifier. Should I include an equivalent “ID” field in the Recipe Steps data type to link the steps to the recipes? Else, how is the link achieved?
I uploaded a sample TSV data file (primary delimiter = tab, secondary delimiter = | ) in three separate stages to the “Recipe Listings”, “Recipe Steps”, and “Recipe Equipment” data types. There’s a single entry in each of these data types.
Questions
How do I display the Recipe Steps list in their repeating group?
Do I need to constrain the search based on a key that links the “Recipe Listings” and “Recipe Steps” data types?
That is going to be really awkward to do it the way you have done. i.e. display the 1st item from this list, and then the 1st item from this list. Then the 2nd item from this list and the 2nd from this list. etc
It will be far easier to have the “steps” as individual things within a list, and then just display that list in the repeating group.