Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 Programming Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 10-12-2008, 05:10 PM
Jhonnyf's Avatar
Jhonnyf Jhonnyf is offline
 
Join Date: Nov 2007
Location: In my mind
Posts: 196
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Why I have this SQL Error in my forum in newpost_complete (with custom field)?

I'm making a hack for my forum... when I use this modifycation in one forum (new and clean) I not have error... but when I put this in another forum.. this show me:

PHP Code:
Database error in vBulletin 3.7.3:

Invalid SQL:
UPDATE thread 
        SET game 
'user1,user2',
        
energiaboss5000,
        
energiainicialboss5000
        WHERE threadid 
'7360';

MySQL Error   Unknown column 'energiaboss' in 'field list'
Error Number  1054
Request Date  
SundayOctober 12th 2008 10:56:52 AM
Error Date    
SundayOctober 12th 2008 10:56:53 AM
Script        
http://www.xxxxxxxxxxxxx.com/newthread.php?do=postthread&f=38
Referrer      http://www.xxxxxxxxxxxxxxx.com/newthread.php?do=newthread&f=38
IP Address    xxxxxxxx
Username      
xxxxxxxxxxx
Classname     
vB_Database
MySQL Version 
5.0.67-log 
I use a plugin hook in "newpost_complete" the is code:

PHP Code:
if ($type == 'thread')
    { 
//make SQL UPDATE

the field "energiaboss" exist in my table (I created using phpMyAdmin)

I disable all my hacks using newpost_complete, and i don't know hy say me "in 'field list'" or maybe I should be add this column using my hack like a product??

Thank you

--------------- Added [DATE]1223836328[/DATE] at [TIME]1223836328[/TIME] ---------------

The same error using the sql sentence in vBulletin SQL QUERY console and using in phpMyAdmin console..... but, when I modify using phpMyAdmin I not have that error and show me the same SQL Sentence


why?? problem update all my records with the new field???

PD: the field exist in my table.... i think that is problem of the MySQL of that hosting (goddady)
Reply With Quote
  #2  
Old 10-13-2008, 08:20 AM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

If the columns do exist in the thread table of the database your board is connecting to, you should not have this error.
Reply With Quote
  #3  
Old 10-13-2008, 11:40 AM
Jhonnyf's Avatar
Jhonnyf Jhonnyf is offline
 
Join Date: Nov 2007
Location: In my mind
Posts: 196
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I hate you MySQL!!!!!!!

when i use SQL (vbulletin or SQL Console en phpMyAdmin) the fields its show
threadid|etc|etc|energiaboss|etc

but when I create a new register (phpMyAdmin) the SQL QUERY that show me was:
PHP Code:
UPDATE thread 
        SET 
'game' 'user1,user2',
        
'                 energiaboss'5000,
        
'energiainicialboss'5000
        WHERE 
'threadid' '7360' 

It had blanks spaces :'(

I Hate you MySQL!!!!
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 07:27 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.06140 seconds
  • Memory Usage 2,191KB
  • Queries Executed 13 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (3)bbcode_php
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (3)post_thanks_box
  • (3)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (3)post_thanks_postbit_info
  • (3)postbit
  • (3)postbit_onlinestatus
  • (3)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete