Title: baynard's Replies | WordPress.org

---

# baynard

  [  ](https://wordpress.org/support/users/baynard/)

 *   [Profile](https://wordpress.org/support/users/baynard/)
 *   [Topics Started](https://wordpress.org/support/users/baynard/topics/)
 *   [Replies Created](https://wordpress.org/support/users/baynard/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/baynard/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/baynard/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/baynard/engagements/)
 *   [Favorites](https://wordpress.org/support/users/baynard/favorites/)

 Search replies:

## Forum Replies Created

Viewing 1 replies (of 1 total)

 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Incorrect File URL’s using http://ywcalancaster.org/wordpress?getfile=xxx](https://wordpress.org/support/topic/incorrect-file-urls-using-httpywcalancasterorgwordpressgetfilexxx/)
 *  [baynard](https://wordpress.org/support/users/baynard/)
 * (@baynard)
 * [15 years, 2 months ago](https://wordpress.org/support/topic/incorrect-file-urls-using-httpywcalancasterorgwordpressgetfilexxx/#post-1524826)
 * Haven’t tried this yet but look forward to getting to it later today. My buddy
   suggested this code to search and replace link broken by UAM:
 * UPDATE `wp_posts` SET `post_excerpt`=`guid` WHERE EXISTS (SELECT *  FROM `wp_posts`
   WHERE `post_content` LIKE ‘%getfile%’ )
 * This selects all the post_content rows that contain the word “getfile” and replaces
   the entire post_content field with the entire guid field. 
 * I notice that there are syntax differences between the two fields, but rather
   than assume you wanted one over the other, the syntax above just moves the guid
   into post_content – if you want additional html, for example the `<a href="` 
   and `">Link Description</a>`,  you can add them to the SET statement, for example:
 * UPDATE `wp_posts` SET `post_excerpt`=`<a href="`+`guid`+`">Link Description</
   a>` WHERE EXISTS …

Viewing 1 replies (of 1 total)