Page 1 of 1
Deleting XP
Posted: Thu Sep 20, 2007 4:37 am
by Seehank
Hi is it possible to delete someones XP? I use MYSQL to store my XP, just need to know whwre to look
Thanx!
--- Please enter the following information for support ---
War3ft Version: 3.0
Amxmodx Version: 1.76d
Metamod Version: 1.19p32
Posted: Thu Sep 20, 2007 9:47 am
by YamiKaitou
Run this query in MySQL
Code: Select all
DELETE * FROM wc3_player`,`wc3_player_extra`,`wc3_player_race`,`wc3_player_skill`
Posted: Thu Sep 20, 2007 12:27 pm
by YamiKaitou
Oh, then I read it wrong. If that is the case, I can do it in 2 queries (could be one, but I am to lazy to try and get it to work)
Code: Select all
SELECT `player_id` FROM `wc3_player` WHERE `player_steamid` = 'PUT THE STEAM ID HERE';
DELETE * FROM `wc3_player`,`wc3_player_extra`,`wc3_player_race`,`wc3_player_skill` WHERE `player_id` = 'PUT THE RESULT OF THE LAST QUERY HERE';
Posted: Sat Oct 06, 2007 12:08 am
by Fyrmn472
So if I want to delte all XP in DB, I query this in MySql:
Code: Select all
DELETE * FROM wc3_player`,`wc3_player_extra`,`wc3_player_race`,`wc3_player_skill`
I'm no expert but something doesn't look right....

Posted: Tue Oct 09, 2007 8:07 am
by YamiKaitou
If you want to delete everyones xp, yes that would be correct
Posted: Wed Oct 10, 2007 11:45 am
by Fyrmn472
That doesn't not work for me. Shouldn't there be a ";" at the end?
Posted: Wed Oct 10, 2007 12:33 pm
by YamiKaitou
Then try this one
Code: Select all
DROP `wc3_player`,`wc3_player_extra`,`wc3_player_race`,`wc3_player_skill`
Posted: Wed Oct 10, 2007 1:11 pm
by Fyrmn472
I tried the DROP query you provided, restarted the game server, reconnected and levels are still where they were. So I cleared the buffer using "\c" and tried the DELETE query you provided. I restarted the game server, reconnected and levels are still where they were.
Here's what I did:
Did I miss something?
Posted: Wed Oct 10, 2007 9:35 pm
by YamiKaitou
According to that, you MUST end you command with a semicolon or \g. I use phpMyAdmin for MySQL, but I also don't use MySQL for AmxX stuff (I use SQLite). Turns out that I had the format wrong, here is the correct format
Code: Select all
DROP TABLE `wc3_player`,`wc3_player_extra`,`wc3_player_race`,`wc3_player_skill`
Posted: Wed Oct 10, 2007 9:44 pm
by Fyrmn472
As I suspected, it worked by adding a ";" to the end.
Code: Select all
DROP TABLE `wc3_player`,`wc3_player_extra`,`wc3_player_race`,`wc3_player_skill`;
Thanks