vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Pls help. SQL query required to recreate a user with an ID of 1. (https://vborg.vbsupport.ru/showthread.php?t=46685)

Mr L 12-15-2002 02:19 AM

Pls help. SQL query required to recreate a user with an ID of 1.
 
I have used an unoffical patch to merge two VB databases together. Worked like a dream.

Later I merged some surplus accounts including the admin one. All seemed fine. A couple of weeks later (now), I notice that my ID has changed to X (new user ID) and the original user ID of 1 is gone. A mistake on my behalf here.

I need to recreate a user account with an ID of 1 and then manually do privilages etc. Can anyone help?

I am assuming that I can run an SQL query, but don't know what to run.

I still have full admin access to the board, but some scripts are not working as they look for user with an ID of 1.

Thanks.

Mr L 12-15-2002 11:31 AM

I've now had some help at vBulletin.Com, but they have recommend I ask you guys for the final piece of the puzzle.

The new user ID created via an SQL query they gave is not number 1. So effectively, I could have done this via the CP.

What I need to do is run a command to alter a users ID to one that I know is not in use as the account is no longer there.

I would be very grateful for any help here.

Xenon 12-15-2002 12:06 PM

hmm, you can just alter your userid

following queries:
[sql]UPDATE user SET userid=1 WHERE userid=x
UPDATE userfield SET userid=1 WHERE userid=x
UPDATE post SET userid=1 WHERE userid=x
UPDATE privatemessage SET userid=1 WHERE userid=x[/sql]

x is you userid now...
after that update the thread information :)


All times are GMT. The time now is 07:40 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.01015 seconds
  • Memory Usage 1,706KB
  • 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)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