title: Store image files or URLs in MySQL database? Which is better?
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/3748/storing-images-in-db-yea-or-nay">Storing Images in DB - Yea or Nay?</a><br>
    <a href="https://stackoverflow.com/questions/2517752/images-in-database-vs-file-system">Images in database vs file system</a>  </p>
  </blockquote>
  
  
  
  <p>I've been developing a web application using RIA technologies (Flex + PHP + MySQL + Ajax) and now I'm in a dilemma about image files.</p>
  
  <p>I use some images in my Flex app, so I think "it could be awesome if I store them into database, and then retrieve from it; consecuently, maintain process should be more easy". But, here is my dilemma:</p>
  
  <p><strong>Should I store the physical URL of my images, or is going to be better if I store directly the image?</strong></p>
  
  <p>For example, should my <code>Cars</code> table looks like:</p>
  
  <blockquote>
    <p><code>ID</code> (autonumeric) | <code>Source</code> (text)</p>
  </blockquote>
  
  <p>or like this?</p>
  
  <blockquote>
    <p><code>ID</code> (autonumeric) | <code>Image</code> (longblob or blob)</p>
  </blockquote>
  
  <p>I know that here are cool people that can answer me this question, explaining me which is better and why :)</p>