User:Andre Castro/2/django/manytomany

From XPUB & Lens-Based wiki

I want to introduce a character model to the database of spam email messages I have been developing.

This will be a way to account for the characters in the spam narratives, either the ones described in them or narrating them.

The character field

I must contain the following fields:

  • Name - CharField(max_length=200, unique=True)
  • Date of Birth - DateField(blank=True)
  • Date of Death - DateField(blank=True)
  • Nationality - CharField(blank=True, max_length=200)
  • Occupation - CharField(blank=True, max_length=200)
  • Biography - TextField(blank=True)
  • Appearances in media - TextField(blank=True)
  • Other - TextField(blank=True)


  • be ManyToMany: a character can be present in more that one email; one email can have more than one character.
  • the LINK TABLE must allow for the misspellings of the character's name (eg: Mr. Castro was spelled Mr. Costro in email#40)