Aug
26th

WordPress and MySQL: What’s Your Wordcount?

Thanks for stopping by my personal blog on Marketing Technology! Over 50,000 visitors a month find my content worth returning for, so don't forget to subscribe to the Marketing Technology Blog RSS feed or to the Marketing Technology Email to have new content sent directly to your inbox. You may also find my other business blog helpful, Social Media Domination.

There’s been some talk on blogs about the average size of a Wordpress post. Some light has been shed that Search Engines will only weigh the impact of the first x number of characters, where x is currently unknown. As a result, anything after that is simply a waste of words.

Image from Wordle!

I’m rather garrulous with my blog posts so I’m going to do some additional analysis and see if the popularity of the post from search results has any correlation to the word count. I won’t get too scientific, but I do want to take a deeper look.

How can I query Wordpress for Word Count?

MySQL doesn’t have a built-in word count function for MySQL, but as with every other unanswered question, some smart guy on the blogosphere already answered how to use MySQL to get a Word Count.

Here’s the author’s word count query modified for a Wordpress database:

SELECT `ID`, `post_date`, `post_type`,
SUM( LENGTH(`post_content`) - LENGTH(REPLACE(`post_content`, ‘ ‘, ”))+1) AS ‘Wordcount’
FROM `wp_posts`
GROUP BY `ID`
HAVING `post_type` = ‘post’
ORDER BY `post_date` DESC
LIMIT 0, 100

I currently don’t subscribe to the ‘perfect post size’ since what really provides weight with a search engine isn’t simply the word count, but the number of links to that content. If you have a 2,000 word post that attracts a lot of link attention, then the right size of your post was 2,000 words.

Give me a few days on this and I’ll do a follow up!

You might also find these posts interesting:

RSS feed | Trackback URI

4 Comments »

Comment by no imageMartin Weiss (SezWho)
2008-08-27 14:21:09

As a result, anything after that is simply a waste of words.

Well, only as long as you write for Google, and not your readers… ;)

Rate this:
3.2
 
2008-08-28 00:16:44

[...] WordPress and MySQL: What’s Your Wordcount? Aug [...]
 
Comment by no imageChetan (SezWho)
2008-08-28 00:26:31

There is a plugin called “Blog Metrics” which tells you the average word count for your blog posts etc. Why not try that?
Rate this:
3.2
 
2008-11-13 00:41:25

[...] and a growing number of subscribers - and I’m never pithy! I analyzed the number of words per post and compared it to post popularity on my own blog and never found a [...]
 
Name (required)
E-mail (required - never shown publicly)
URI
Your Comment (smaller size | larger size)
You may use <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> in your comment.

My Comment Policy: I moderate comments. Please be patient:

  • Spam will happily be destroyed.
  • Use your real name, not some keywords. Otherwise it will be destroyed.
  • Mean comments aren't necessary. If I don't post them I will reply personally to let you know why.
  • Lewd comments will be edited, I don't want my readers leaving because of offensive content.
Great debate, criticism and colorful commentary is always appreciated and approved!