Return to Snippet

Revision: 11274
at January 29, 2009 17:10 by tgbdad


Initial Code
UPDATE url_alias SET dst = REPLACE(src,'node/','issues/issue') WHERE src IN (SELECT CONCAT('node/', CAST(nid as CHAR)) FROM node WHERE type = 'project_issue') AND dst NOT LIKE 'issues/issue%';

Initial URL

                                

Initial Description
I currently have project_issue nodes set for replacement pattern issues/issue[nid] in Drupal 5.x PathAuto. This query fixes all of the URL aliases for entries created before this was set correctly.

Initial Title
Fix screwy URL aliases for project_issue nodes

Initial Tags
mysql, drupal

Initial Language
MySQL