Chicken, egg, data model

What comes first, `chicken_id`, `egg_id` or `makechicken()`?

Chicken, egg, data model

While working on GrabbrApp I've run into the fun problem of figuring out just how much of my data model I need to have figured out to nail down the functionality of the application.

I don't have Auth yet, but I need to be able to tie tasks to users. I don't have all of the different types of tasks enumerated yet, but I need to have some idea of their structure in order to plan out shared attributes and how they relate to each other.

It's a classic chicken and egg scenario: what comes first, the full functionality described by the data model, or the data model that describes it?

Ideally, a data model should be fairly modular. There should be interrelationships between data schemas, but there shouldn't be as many dependencies. A given task should have a user-id field, but it shouldn't require any of the attributes that are associated with the user. Two result objects might be related in that they are results of the same task, so they'll share the same task-id but they shouldn't be dependent on each other. If they are, they should probably just be one result object.

Considering the fact that GrabbrApp is a pretty backend heavy application, the data model is pretty vital. I definitely will want to get it right.