I would like to store an object FOO in a database. Lets say FOO contains three integers and a list of \"Fruits\".
The list can have any len
Some databases allow multiple values to be stored in a single column of a single row, but it is generally more convenient to use a separate table.
Create a table with two columns, one that contains pointers to the primary key of the objects table, and one that contains pointers to the primary key of the fruit table. Then, if an object has three fruit, there are three rows in the object_fruit table that all all point to the same object, but to three different fruit.