title: How to create foreign key that is also a primary key in MySQL?
body: <p>This should be a fairly straightforward question, but I'm unable to find an easy answer.  How do you create a foreign key that is also a primary key in MySQL?  Here's my current attempt:</p>
  
  <pre><code>CREATE TABLE Sale(
      sale_id CHAR(40),
      PRIMARY KEY(sale_id),
      discount DOUBLE,
      type VARCHAR(255),
      price DOUBLE,
      );
  
  CREATE TABLE Normal_Sale(
      sale_id CHAR(40),
      PRIMARY KEY(sale_id);
  );
  
  CREATE TABLE Special_Sale(
      sale_id CHAR(40),
      PRIMARY KEY(sale_id);
  );
  </code></pre>
  
  <p>What am I missing here?</p>
  
  <p>Thanks in advance.</p>