Tips and Tricks HQ Support

Support site for Tips and Tricks HQ premium products

  • Home
  • Contact Us
  • Documentation
  • Forum Home
    • Forum
    • Forum Search
    • Forum Login
    • Forum Registration

eMember writes commas in mysql database records producing errors.

by

Tips and Tricks HQ Support Portal › Forums › WP eMember › WP eMember Troubleshooting › eMember writes commas in mysql database records producing errors.

  • This topic has 2 replies, 3 voices, and was last updated 11 years, 6 months ago by nur.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • December 1, 2013 at 1:04 pm #10142
    lorenzogiacomini
    Member

    Hello,

    I’ve noticed that eMember, when auto-upgrades to a new membership level,

    has a strange behaviour in updating more_membership_levels column in the

    wp_eMember_members table.

    As you can see in this image: [http://goo.gl/ndXFNS]

    it puts commas in front of the membership level code.

    This behaviour produces database errors as you can see below in this piece

    of error log:

    [30-Nov-2013 10:24:18 UTC] WordPress database error You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ’87 )’ at line 1 for query SELECT * FROM wp_wp_eMember_membership_tbl WHERE id IN ( ,87 ) made by require(‘wp-blog-header.php’), require_once(‘wp-load.php’), require_once(‘wp-config.php’), require_once(‘wp-settings.php’), do_action(‘plugins_loaded’), call_user_func_array, emember_bootstrap, Emember_Auth::getInstance, Emember_Auth->__construct, Emember_Auth->setPermissions, dbAccess::findAll

    This behaviour tends to slow down the website.

    Thank you

    Lorenzo Giacomini

    December 1, 2013 at 2:17 pm #59355
    mbrsolution
    Spectator

    Hello Lorenzo Giacomini, please load a fresh new copy of the plugin and see if that works.

    https://support.tipsandtricks-hq.com/forums/topic/re-install-or-load-a-fresh-build-of-the-plugins

    December 1, 2013 at 4:06 pm #59356
    nur
    Member

    in case you are still seeing the error. you can try replacing:

    Code:
    $my_secondary_levels = dbAccess::findAll(WP_EMEMBER_MEMBERSHIP_LEVEL_TABLE,
    ‘ id IN ( ‘ . $this->userInfo->more_membership_levels . ‘ ) ‘);

    ( line 558 ~ 560 if you have latest version)

    with:

    Code:
    $my_secondary_levels = dbAccess::findAll(WP_EMEMBER_MEMBERSHIP_LEVEL_TABLE,
    ‘ id IN ( ‘ . trim($this->userInfo->more_membership_levels,’,’) . ‘ ) ‘);

  • Author
    Posts
Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.
Log In

Forum Related

  • Forum Home
  • Forum Search
  • Forum Registration
  • Forum Login

Support Related Forms

  • Contact Us
  • Customer Support
  • Request a Plugin Update
  • Request Fresh Download Links

Useful Links

  • Plugin Upgrade Instructions
  • WP eStore Documentation
  • WP eMember Documentation
  • WP Affiliate Platform Documentation
  • Tips and Tricks HQ Home Page
  • Our Projects

Quick Setup Video Tutorials

  • WP eStore Video Tutorial
  • WP eMember Video Tutorial
  • WP Affiliate Platform Video Tutorial
  • Lightbox Ultimate Video Tutorial

Our Other Plugins

  • WP Express Checkout
  • Stripe Payments Plugin
  • Simple Shopping Cart Plugin
  • Simple Download Monitor

Copyright © 2025 | Tips and Tricks HQ