title: SQL query to remove certain text from each field in a specific column?
body: <p>I recently recoded one of my sites, and the database structure is a little bit different.</p>
  
  <p>I'm trying to convert the following:</p>
  
  <pre><code>*----*----------------------------*
  | id | file_name                  |
  *----*----------------------------*    
  | 1  | 1288044935741310953434.jpg |
  *----*----------------------------*
  | 2  | 1288044935741310352357.rar |
  *----*----------------------------*
  </code></pre>
  
  <p>Into the following:</p>
  
  <pre><code>*----*----------------------------*
  | id | file_name                  |
  *----*----------------------------*    
  | 1  | 1288044935741310953434     |
  *----*----------------------------*
  | 2  | 1288044935741310352357     |
  *----*----------------------------*
  </code></pre>
  
  <p>I know that I could do a foreach loop with PHP, and explode the file extension off the end, and update each row that way, but that seems like way too many queries for the task.</p>
  
  <p>Is there any SQL query that I could run that would allow me to remove the file exentision from each field in the <code>file_name</code> column?</p>