Post Pacific  

Go Back   Post Pacific > Восстановленный архив > Темы без сохранившегося раздела
FAQ Community Calendar Today's Posts Search

Notices

 
 
Thread Tools Search this Thread Display Modes
Old 26.09.2006, 11:57   #1
kin
Архивный участник
 
Join Date: Sep 2006
Posts: 882
Default [Share] How to delete char/account

Found a lot of threads about deleting but no one has the end.
As I understand we can find char_ID and use "lin_DeleteChar" from Stored Procedures in Lin2world on your server. It will delete the char but left all data in tables.
I haven't found the procedure to delete account. So it just 2 question left.
1. How to delete account?
2. Is there any way to delete char from database complitelly?
kin is offline  
Old 26.09.2006, 12:15   #2
FidoW
Архивный участник
 
Join Date: Sep 2005
Posts: 1,014
Default

2:

DELETE FROM user_data WHERE char_id =
DELETE FROM user_item WHERE warehouse BETWEEN 0 AND 1 AND char_id =
DELETE FROM user_skill WHERE char_id =
DELETE FROM user_data WHERE char_id =
DELETE FROM user_macro WHERE char_id =
DELETE FROM user_log WHERE char_id =
DELETE FROM user_history WHERE char_id =
....

etc etc...


1:

DELETE FROM user_account WHERE uid =
DELETE FROM ssn WHERE ...
....
same as char... look for all tables and create a little script to do it more easy
FidoW is offline  
Old 26.09.2006, 12:35   #3
kin
Архивный участник
 
Join Date: Sep 2006
Posts: 882
Default

Yep, I understand that, but wouldn't this create any errors in the game?
Especially when I have this:https://postpacific.loc-online.com/f...ead.php?t=5860

I already created the querry for all tables, but do not want to have an error
kin is offline  
Old 26.09.2006, 17:36   #4
kin
Архивный участник
 
Join Date: Sep 2006
Posts: 882
Default

Here is the query which deletes the selected Char. Just put char_id instead of xx and run. Char_id could be found in User_data table. Soon will post the query to delete an account.
Actually I want to create the script which you could run from your web page

P.S. Rar file updated

Вложения из исходного сообщения (сами файлы в копии отсутствуют):
full_char_delete.rar — 473 байт
kin is offline  
Old 26.09.2006, 18:58   #5
FidoW
Архивный участник
 
Join Date: Sep 2005
Posts: 1,014
Default

Be carefull with this -> DELETE FROM user_item WHERE char_id = xx

You can delete CLAN WAREHOUSE with this query.

The correct one would be
DELETE FROM user_item WHERE char_id = xx AND warehouse BETWEEN 0 AND 1
FidoW is offline  
Old 26.09.2006, 19:16   #6
kin
Архивный участник
 
Join Date: Sep 2006
Posts: 882
Default

Wow! That's why you posted it on your firs post Didn't understand it
But if the warehouse will be 3 for example, what will happen if char_id stays there? Would that cause an error? And anyway, if I delete using CHAR_ID, the warehouse could be deleted if that char is the lider, but if I delete char, it would give the error anyway, as only lider of the clan could take something from warehouse.
What do you think?
kin is offline  
Old 27.09.2006, 03:34   #7
elcapo
Архивный участник
 
Join Date: Mar 2005
Posts: 107
Default

May be, a db mantenaince's script deleting al characters (or accounts) that havent been used since a x period of time , could be good ^^
elcapo is offline  
Old 27.09.2006, 08:40   #8
kin
Архивный участник
 
Join Date: Sep 2006
Posts: 882
Default

You could modify my script to do it. just add few lines
kin is offline  
 


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 18:53.