title: Enum vs Reference table vs Lookup class
body: <p>While I'm designing a <strong>MySQL database</strong> for a dating website, I have come with the doubt of how to store the referenced data. Currently the database has 33 tables and there are nearly 32 different fields who need to be referenced. We have to consider as well that many of these elements need to be translated.</p>
  
  <p>After been reading several opinions, I have almost <strong>dismissed to use enum</strong> like:</p>
  
  <pre><code>CREATE TABLE profile (
    'user_id' INT NOT NULL,
   ...
    'relationship_status' ENUM('Single','Married') NOT NULL,
   ... 
  );
  </code></pre>
  
  <p>And normally I would be using a <strong>reference table</strong> like:</p>
  
  <pre><code>CREATE TABLE profile (
    'user_id' INT NOT NULL,
   ...
    'relationship_status_id' INT NOT NULL, 
   ... 
  );
  
  CREATE TABLE relationship_status (
    'id' INT NOT NULL,
    'name' VARCHAR(45) NOT NULL,
    PRIMARY KEY ('id') 
  );
  </code></pre>
  
  <p>But it might be over-killed to create 32 tables so I'm considering to code it in <strong>PHP</strong> like this: </p>
  
  <pre><code>class RelationshipStatusLookUp{
    const SINGLE = 1;
    const MARRIED = 2;
  
    public static function getLabel($status){
        if($status == self::SINGLE)
           return 'Single';
        if($status == self::MARRIED)
           return 'Married';
        return false;
    }
  }
  </code></pre>
  
  <p>What do you think? Because I guess it could improve the performance of the queries and also make easier the development of the whole site.</p>
  
  <p>Thanks.</p>