Support » Fixing WordPress » SQL command with Tags

  • Is there a SQL command I can use to add the author name to the tags of all their posts.

    For example. If I have an author named, “David” – Is there a command that will add “David” as a tag to all his posts?


Viewing 2 replies - 1 through 2 (of 2 total)
  • Um, not that I know of. It would require some recursiveness, in that you do not know which posts an author is attached to until after you have performed a query, but you do need to know them to add the author’s name to each as a tag.

    EDIT: Perhaps someone with advanced MySQL skills can suggest something where you can store the posts (well, their IDs, as they’re all you need) from an initial query to a temporary table, then read off that table in a followup query to add the tags. Sadly, I’m not that fella.

    It’s ok. Thanks anyways!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘SQL command with Tags’ is closed to new replies.