vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   userid set to 0 in many rows in post table - HELP (https://vborg.vbsupport.ru/showthread.php?t=55307)

Master Computer 07-15-2003 08:58 PM

userid set to 0 in many rows in post table - HELP
 
There are some threads when I send the reply to; I see these lines when it's supposed to redirect me to the thread page:
Code:

Database error in vBulletin 2.2.8:
 
Invalid SQL: SELECT SUM(views) AS personalviews FROM thread
WHERE postuserid= AND open!='10'
mysql 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 'AND open!='10'' at line 1
mysql error number: 1064 ....

The strange thing I found is that there were many rows in post table which have userid=0 while other columns for those rows are fine.
I can fix that manually and set the userid to the related one with the same username column in user table.
But that way won't be practical when I have more than 7000 rows suffering from this problem.
Any help for a query/script to fix that?
Thanks in advance for your help.

SmEdD 07-15-2003 09:07 PM

Did you delete users? 0 = guest or deleted user.

Master Computer 07-15-2003 09:10 PM

I didn't delete users.
besides, those users having the posts do exist and not deleted.


All times are GMT. The time now is 06:22 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.00948 seconds
  • Memory Usage 1,709KB
  • 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
  • (1)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (3)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