vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=251)
-   -   Database error (https://vborg.vbsupport.ru/showthread.php?t=318768)

bosanci28 05-22-2015 07:25 PM

Database error
 
Hello,

I am getting some emails with "Database error" message from my forum and not really sure why!

This is what i get:

>>>>>>>>>>>>>>>>>>>>>>>>>>>>

Database error in vBulletin 4.2.2:

Invalid SQL:
SELECT location, badlocation FROM session WHERE userid = n AND lastactivity > 0 ORDER BY lastactivity DESC LIMIT 1;

MySQL Error : Unknown column 'n' in 'where clause'
Error Number : 1054
Request Date : Wednesday, May 20th 2015 @ 10:36:02 PM
Error Date : Wednesday, May 20th 2015 @ 10:36:03 PM
Script : forum link it is in here....(deleted by me)
Referrer :
IP Address : xxx.xx.xxx.xxx
Username : Unregistered
Classname : vB_Database
MySQL Version :

>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

Ip address is changed all the time,in every email ! so i guess there are from different people.

Thank for any advice on this.
B.

Lynne 05-22-2015 07:27 PM

How can you have a userid of "n"? "n" is a letter, not a number and the userid must be a number.

bosanci28 05-22-2015 07:52 PM

1 Attachment(s)
Hmm, i am not sure whats with the "n" in there as is not in the user groups.

MarkFL 05-22-2015 09:08 PM

I would guess it is a "Who's Online" related query...have you recently installed any new add-ons that report user location or activity of any kind?

ForceHSS 05-22-2015 09:19 PM

The Script part of the error can you post it we need to see what script caused the error

bosanci28 05-22-2015 09:50 PM

1 Attachment(s)
See attached , i did installed quite few mods as my forum is new and getting started.
But i suspect maybe is the mod: "member tracking" but not sure.

ETS|LuucEarth 05-22-2015 09:51 PM

My guess is that the n should be a variable $n or something along that line. Depends on the script that is calling this Query.

ForceHSS 05-22-2015 10:01 PM

Disable plugins via config if this fixes the problem enable plugins again via config, then disable one plugin at a time until you find the problem one

To temporarily disable the plugin system, edit includes/config.php and add this line right under <?php

PHP Code:

define('DISABLE_HOOKS'true); 

To enable plugins again just comment out the line
PHP Code:

//define('DISABLE_HOOKS', true); 

Use notepad++ to edit any files

bosanci28 05-24-2015 02:34 AM

Thank you to all for helping!

Okay, So i have disabled , that plugin "Member Tracking" and today i still got about 6 emails with the same message .

So i have i disabled all plugins via config.php and now will give it a day or two to see if the error
comes back.

Thank you.
B.

Lynne 05-24-2015 08:03 PM

If you get the error again, can you please include the Script and Referrer so we can see what script and page the error is coming from.

bosanci28 05-25-2015 01:40 AM

So is all most 24 hr's , from the time i have disabled all the plugins, and my last email that i got
regarding the database error was 05/23/2015 @ 5:58pm. So at this point i don't think is the script i guess. But will try to enable the mods one by one and see.

ForceHSS 05-25-2015 08:03 AM

If you want help please follow what post 10 is asking


All times are GMT. The time now is 08:18 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01133 seconds
  • Memory Usage 1,733KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (12)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete