Wordpress Plugin - Database Problem

Discussion in 'WordPress' started by bschneider5, Dec 4, 2005.

  1. #1
    I recently tried to install the related posts plugin on my blog, but after installing it, this is what I got:

    WordPress database error: [The used table type doesn’t support FULLTEXT indexes]
    SELECT ID,post_title,post_content,post_excerpt,post_date, MATCH(post_title,post_content) AGAINST (’The Bush Iraq Strategy’) AS score FROM wp_posts WHERE MATCH (post_title,post_content) AGAINST (’The Bush Iraq Strategy’) and post_status = ‘publish’ and id 162 LIMIT 0,5

    Am I dead in the water or is there a way I can overcome this? I use dreamhost for all my database/server stuff.
     
    bschneider5, Dec 4, 2005 IP
  2. tflight

    tflight Peon

    Messages:
    617
    Likes Received:
    38
    Best Answers:
    0
    Trophy Points:
    0
    #2
    MySQL has different types of tables. The error you are getting is that the table type you are using for your MySQL database doesn't support FULLTEXT indexes. Fulltext indexing is the basis behind the related posts plug-in.

    My guess is that dreamhost is using the InnoDB table type which while it does support transactions, does not support fulltext indexing. In short, your table type needs to be MyISAM in order for fulltext searching to work.

    I would export a copy of your current database data, then create a new one with the MyISAM type (or contact your host to do this) then reimport your data if necessary.
     
    tflight, Dec 4, 2005 IP
  3. tflight

    tflight Peon

    Messages:
    617
    Likes Received:
    38
    Best Answers:
    0
    Trophy Points:
    0
    #3
    If you have access to a place where you can run SQL commands, you can use the following to switch the table type to MyISAM. (I'd still make a backup of the table before running the query.)

    ALTER TABLE `wp_posts` TYPE=MyISAM;
     
    tflight, Dec 4, 2005 IP
  4. bschneider5

    bschneider5 Active Member

    Messages:
    1,009
    Likes Received:
    44
    Best Answers:
    0
    Trophy Points:
    88
    #4
    Will this give me any other problems?
     
    bschneider5, Dec 4, 2005 IP
  5. tflight

    tflight Peon

    Messages:
    617
    Likes Received:
    38
    Best Answers:
    0
    Trophy Points:
    0
    #5
    It shouldn't. MyISAM is the default, and more commonly used table type.
     
    tflight, Dec 4, 2005 IP
  6. bschneider5

    bschneider5 Active Member

    Messages:
    1,009
    Likes Received:
    44
    Best Answers:
    0
    Trophy Points:
    88
    #6
    Well, I changed the table type and this is wat I'm getting now:



    WordPress database error: [Can't find FULLTEXT index matching the column list]
    SELECT ID,post_title,post_content,post_excerpt,post_date, MATCH(post_title,post_content) AGAINST ('Amazon.com gift certificates') AS score FROM wp_posts WHERE MATCH (post_title,post_content) AGAINST ('Amazon.com gift certificates') and post_status = 'publish' and id <> 176 LIMIT 0,5

    Any ideas?
     
    bschneider5, Dec 5, 2005 IP
  7. Googles76

    Googles76 Peon

    Messages:
    664
    Likes Received:
    26
    Best Answers:
    0
    Trophy Points:
    0
    #7
    My guess is either your wordpress is out of date or your plugin is out of date. Check that you have the latest of everything
     
    Googles76, Dec 5, 2005 IP
  8. tflight

    tflight Peon

    Messages:
    617
    Likes Received:
    38
    Best Answers:
    0
    Trophy Points:
    0
    #8
    Yes, you need to run the setup script for the plugin again since it failed before when the table was the incorrect type. If you go to your Admin section and look at the plugin list you should see a link to "setup scrip" inside the description of the related posts plugin. Click on the link and it should create the missing index.
     
    tflight, Dec 5, 2005 IP
  9. bschneider5

    bschneider5 Active Member

    Messages:
    1,009
    Likes Received:
    44
    Best Answers:
    0
    Trophy Points:
    88
    #9
    Here is the description:
    Show last 5 contextually related posts on single blog posts, increase exposure

    Is there another plugin I should use?
     
    bschneider5, Dec 5, 2005 IP
  10. tflight

    tflight Peon

    Messages:
    617
    Likes Received:
    38
    Best Answers:
    0
    Trophy Points:
    0
    #10
    Hugh, yea, silly me for thinking there was only one of those kicking around. Perhaps just uninstall and reinstall the plugin will create the index again.

    If not the related posts plugin I use I got from here and works quite nicely.
     
    tflight, Dec 5, 2005 IP
  11. bschneider5

    bschneider5 Active Member

    Messages:
    1,009
    Likes Received:
    44
    Best Answers:
    0
    Trophy Points:
    88
    #11
    I finally got it working!!!!Finally!

    If you could help me with one moe thing that would be great. If you look at this page, you can see the plugin is working. However, I need it to be a little bit to the right. What code would I insert to fix this problem? http://www.bradsblog.net/?p=171

    Thanl you SOOOOOOOO much
     
    bschneider5, Dec 5, 2005 IP
  12. tflight

    tflight Peon

    Messages:
    617
    Likes Received:
    38
    Best Answers:
    0
    Trophy Points:
    0
    #12
    Without dissecting or testing this you could try surrounding the related posts HTML code with the following div

    <div class="postinput">
         <!-- Your Related Posts code here !-->
    </div>
    HTML:
    In your CSS file the postinput class gets a 10px left margin so that would probably work.
     
    tflight, Dec 5, 2005 IP
  13. bschneider5

    bschneider5 Active Member

    Messages:
    1,009
    Likes Received:
    44
    Best Answers:
    0
    Trophy Points:
    88
    #13
    Thanks Tflight, that didn't move it over enough so I just made a new class and made it 25 pixels. This works out great. Thnks for all the help!
     
    bschneider5, Dec 6, 2005 IP
  14. Joaquin357

    Joaquin357 Peon

    Messages:
    5
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #14
    Hello from Joaquin
    I was getting the same error for awhile on my first page on my very first two WordPress blogs.
    So I went to plugins/Related Post Options and ran the script for SQL Index Table Setup.
    Wow it worked. Beautiful. I'm very happy to have seen your post bschneider5, tflight, & Tauren and of course to have gotten help. Thank You Very Much:):):)
    We have lift off!!!

    Joaquin
     
    Joaquin357, Mar 27, 2008 IP