vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Malformed SQL Query (https://vborg.vbsupport.ru/showthread.php?t=60791)

Kaelon 01-26-2004 08:39 PM

Malformed SQL Query
 
Hi, Gang,

So, I've run into a bit of a problem with Mike's Warning System for vB 2.3.x Series, and specifically, it involves a malformed query.

It seems like a malformed query when trying to edit a user that has been automatically banned by the system (i.e., placed in the banned usergroup). Even when the warning period has expired, I can't seem to be able to move back the banned user to the active usergroups. Thoughts?

The exact error message I receive:

Code:

Database error in vBulletin Control Panel 2.3.2:

Invalid SQL: UPDATE user SET birthday='1971-05-23',options='15',usergroupid='10',username='Melegaunt Tanthul',email='Bevin_van_liempt@hotmail.com',styleid='0',parentemail='',coppauser=0,homepage='',icq='309268104',aim='Whiterose1234321',yahoo='',signature='White pants, white shirt , white gloves, white boots, white hair, and white eyes (glowing).  His beloved warlord sword, \"Demonslayer\" is elven steel, white, glittering, and bears the likeness of a whiterose.  It\'s sheath is white elven steel. Its hilt is sweat absorbant.',adminemail=1,showemail=1,invisible=0,usertitle='Companion',customtitle=0,joindate=UNIX_TIMESTAMP('2003-12-24 03:18:11'),cookieuser=1,nosessionhash=1,daysprune='1000',lastvisit=UNIX_TIMESTAMP('2004-01-25 20:15:18'),lastactivity=UNIX_TIMESTAMP('2004-01-25 20:43:15'),lastpost=UNIX_TIMESTAMP('2004-01-25 15:22:19'),posts='97',timezoneoffset='-8',emailnotification=0,receivepm='1',emailonpm='1',ipaddress='206.116.243.178',pmpopup=IF(pmpopup=2 AND =1,pmpopup,'') WHERE userid=12221
mysql error: You have an error in your SQL syntax near '=1,pmpopup,'') WHERE userid=12221' at line 1

mysql error number: 1064

Date: Monday 26th of January 2004 03:46:55 PM
Script: http://www.alleria.com/forums/forums/admin/user.php
Referer: http://www.alleria.com/forums/admin/...t&userid=12221


assassingod 01-26-2004 08:50 PM

You may have incorrectly installed the hack. Try uploading an unhacked user.php and re-editing the file for the hack.

Xenon 01-26-2004 08:54 PM

its the part
Code:

pmpopup=IF(pmpopup=2 AND =1,pmpopup,'')
which is the problem

Kaelon 01-27-2004 09:51 PM

Thanks. I hadn't modified user.php as a result of the hack, however, I had added a subroutine into global.php, which when it queried the user account, rendered it uneditable via the Admin CP. Very shoddy work -- I had no idea what the query was originally intended to do, but I removed the hack, and I think someone should move it to Beta Hacks, rather than keep it afloat in Full Releases. It's a shame, because you won't really notice the corruption until the Warnings System starts banning your users.


All times are GMT. The time now is 02:20 PM.

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.02319 seconds
  • Memory Usage 1,717KB
  • 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_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (4)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