Topic: I have deleted users table
I have deleted 'users' table in DB.
How Can I fix the forum. Is it possible?
I need any advice !
And what parametres must have admin in db ?
You are not logged in. Please login or register.
PunBB Forums → PunBB 1.2 troubleshooting → I have deleted users table
I have deleted 'users' table in DB.
How Can I fix the forum. Is it possible?
I need any advice !
And what parametres must have admin in db ?
That will be very difficult to fix.
if you have 2 users, perhaps not that hard, but if you have 200, you most likely need a backup to use(soo much manual work to figure out everything), and by your question I guess you haven't made a backup ...
(that reminds me, time to do a backup on all my webstuff)
extract them from posts table bby execute SQL
insert into punbb_en_users (id, username, password)
(select poster_id ,poster, md5('hedden password') from punbb_en_posts
where poster_id>0
group by poster_id, poster)
but all of users have new password 'hidden password' change it to any string before execute SQL and do not give it to any one.
thay cannot login and request new password so ask them to send you a new email and you will send them a new password and correct email addresses.
Backup your database, and dont play with fire
EDIT
change tables name in code to correct names
punbb_en_users
punbb_en_posts
if a user have made 1000 posts, will it really be 1 row added in the users table then?
i assume thats what group by poster_id, poster does
aah
i like "group by" instead "distent"
insert into punbb_en_users (id, username, password)
(select distinct poster_id ,poster, md5('hedden password') from punbb_en_posts
where poster_id>0)
Done
The main difficulty was to put all that users in the same order ... cause in other case there is a post mixture. Got the information from the posts table.
Have wasted a lot of time
now, do a backup, just in case you do decide to delete something again
I have memory about crashing my harddisk, you must see my face it is like Frankishtine
PunBB Forums → PunBB 1.2 troubleshooting → I have deleted users table
Powered by PunBB, supported by Informer Technologies, Inc.