NoodleFood Authors, Now Fixed

 Posted by on 3 December 2013 at 2:00 pm  NoodleFood, Personal, Technology
Dec 032013
 

This weekend, I fixed the only major lingering headache from the process of converting NoodleFood from Blogger to WordPress. During that conversion, the author data was lost, such that “Diana Hsieh” was listed as the author of every post, even though just over 1,000 of NoodleFood’s more than 6,000 posts were written by someone else, mostly Paul.

I’d procrastinated on the task of fixing that for over a year and half because I feared that I’d have to update every post not written by me by hand. That would have been mighty, mighty unpleasant work.

However, I’m pleased to report that my technical skills — particularly my regex geekery — came in handy, such that I was able to automate the update by spending a few hours massaging the data. I had to:

  1. Extract data about posts authored by people other than me from Blogger’s exported XML file

  2. Integrate that with htaccess redirections so as to obtain a unique WordPress post ID for each of those posts

  3. Create and issue appropriate commands to SQL to update the relevant 1000 entries in the posts table with the correct author id

Much to my delight, that worked just fine, despite a few hiccups and setbacks.

I’m so grateful for my prior existence as a web programmer and sysadmin. I’ve been able to do so much with Philosophy in Action as a result of those skills. Even now, I surprise myself with what I can do! Heck, now that I’ve mucked around in SQL again for the first time in a few years, I might make use of that for some future projects and upgrades. That would make much of Philosophy in Action’s backend so much cleaner and easier to manage, I think.

   
Suffusion theme by Sayontan Sinha