DU: Don't ask me why, but I got the idea today to create a contact manager with Django, mostly as a learning exercise.
Instead of doing it the 'easy' way, I had the dumb idea to make it 'dynamic'. What does that mean? I'm glad you asked. Here's how I see the database tables (I've omitted primary keys): contacts -- firstname, lastname field_definitions -- name, description, valid_regexp fields -- value, contact, field_definition Each contact could have as many or as few bits of information associated with it. I could create a default set of field definitions, ie. "Street Address", "Phone Number", etc. Field definitions could later be added dynamically, because maybe I want to start tracking Birthdays, or URLs, or other things I don't know yet. How dumb is this idea? It's not really an M2M relationship, more like an M2M with intermediary data. I found this: http://code.djangoproject.com/ticket/6095 But this patch is not merged yet. Is there some other way to approach this problem? Am I wasting my time? Also, let's say I actually figure out how to do this...and when I look at a contact's information I retrieve all of the values that link to that contact...how could I intelligently order those values? Let's say some of the field definitions are "Street Address", "City", "State", and "Zip code", I would want them displayed in a certain order...hmmmm....not sure how to handle that. -cjl --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---