Raised This Month: $12 Target: $400
 3% 

SuperHero MySQL save


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
DOG09
Member
Join Date: Feb 2011
Old 10-19-2013 , 07:44   SuperHero MySQL save
Reply With Quote #1

Hey i'am trying to save xp to MySQL at first i created Database then i putet mysql to shconfig.cfg and changed plugins-superhero.ini to MySQL. Then i putet on server amx_shvaulttosql
Code:
Please wait while the XP data is copied
L 10/19/2013 - 14:43:46: [superheromodmysql.amxx] DEBUG: Error Loading MySQL XP for [BOT]Want_vip?_Write_/sms: [1146] 'Table 'np67233_xp.sh_savexp' doesn't exist' - 'SELECT `XP`, `HUDHELP`, `SKILL_COUNT` FROM `sh_savexp` WHERE `SH_KEY` = '[BOT]Want_vip?_Write_/sms''
L 10/19/2013 - 14:43:46: [superheromodmysql.amxx] DEBUG: Error Loading MySQL XP for [BOT]Foorum:_fixcs.net: [1146] 'Table 'np67233_xp.sh_savexp' doesn't exist' - 'SELECT `XP`, `HUDHELP`, `SKILL_COUNT` FROM `sh_savexp` WHERE `SH_KEY` = '[BOT]Foorum:_fixcs.net''
L 10/19/2013 - 14:43:46: [superheromodmysql.amxx] DEBUG: Error Loading MySQL XP for [BOT](1)Foorum:_fixcs.net: [1146] 'Table 'np67233_xp.sh_savexp' doesn't exist' - 'SELECT `XP`, `HUDHELP`, `SKILL_COUNT` FROM `sh_savexp` WHERE `SH_KEY` = '[BOT](1)Foorum:_fixcs.net''
L 10/19/2013 - 14:43:46: [superheromodmysql.amxx] DEBUG: Error Loading MySQL XP for c[F]L - qwer:): [1146] 'Table 'np67233_xp.sh_savexp' doesn't exist' - 'SELECT `XP`, `HUDHELP`, `SKILL_COUNT` FROM `sh_savexp` WHERE `SH_KEY` = 'c[F]L - qwer:)''
L 10/19/2013 - 14:43:46: [superheromodmysql.amxx] DEBUG: Error Loading MySQL XP for SoundWave mp.4: [1146] 'Table 'np67233_xp.sh_savexp' doesn't exist' - 'SELECT `XP`, `HUDHELP`, `SKILL_COUNT` FROM `sh_savexp` WHERE `SH_KEY` = 'SoundWave mp.4''

L 10/19/2013 - 14:43:46: [superheromodmysql.amxx] DEBUG: Error Loading MySQL XP for 1: [1146] 'Table 'np67233_xp.sh_savexp' doesn't exist' - 'SELECT `XP`, `HUDHELP`, `SKILL_COUNT` FROM `sh_savexp` WHERE `SH_KEY` = '1''
Saved XP has been copied from the vault to the MySQL Database Successfully
I checked phpmyadmin and there's nothing.. and when i made restart to the serve and waited to a second round to load XP it wouldn't load my XP-s, WHY?? Houpe you guys understand my problem.

Last edited by DOG09; 10-19-2013 at 11:53.
DOG09 is offline
DOG09
Member
Join Date: Feb 2011
Old 10-19-2013 , 07:51   Re: SuperHero MySQL save
Reply With Quote #2

and when i was trying to put these dabels to MYSQL it show's me error like:
Quote:
#1064 - 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 '(30) NOT NULL,
`XP` int(10) NOT NULL default '0',
`HUDHELP` tinyint(3) unsig' at line 8
DOG09 is offline
DOG09
Member
Join Date: Feb 2011
Old 10-19-2013 , 07:52   Re: SuperHero MySQL save
Reply With Quote #3

But it's default .sql what i taked from that vittu superhero post..
DOG09 is offline
DOG09
Member
Join Date: Feb 2011
Old 10-19-2013 , 09:56   Re: SuperHero MySQL save
Reply With Quote #4

And now it show's me that:
Quote:
L 10/19/2013 - 16:54:08: [superheromodmysql.amxx] DEBUG: Error Loading MySQL XP for VorTeX: [1146] 'Table 'np67233_xp.sh_savexp' doesn't exist' - 'SELECT `XP`, `HUDHELP`, `SKILL_COUNT` FROM `sh_savexp` WHERE `SH_KEY` = 'VorTeX''
L 10/19/2013 - 16:54:08: [superheromodmysql.amxx] DEBUG: Error Loading MySQL XP for c[F]L - qwer: [1146] 'Table 'np67233_xp.sh_savexp' doesn't exist' - 'SELECT `XP`, `HUDHELP`, `SKILL_COUNT` FROM `sh_savexp` WHERE `SH_KEY` = 'c[F]L - qwer''
but why it's not update my MySQL?
DOG09 is offline
DOG09
Member
Join Date: Feb 2011
Old 10-19-2013 , 10:57   Re: SuperHero MySQL save
Reply With Quote #5

Quote:
#----------------------------------------------------
# Start: Create the tables
#----------------------------------------------------

CREATE TABLE IF NOT EXISTS `sh_savexp` (
`SH_KEY` varchar(32) binary NOT NULL default '',
`PLAYER_NAME` varchar(32) binary NOT NULL default '',
`LAST_PLAY_DATE` timestamp(30) NOT NULL,
`XP` int(10) NOT NULL default '0',
`HUDHELP` tinyint(3) unsigned NOT NULL default '1',
`SKILL_COUNT` tinyint(3) unsigned NOT NULL default '0',
PRIMARY KEY (`SH_KEY`)
) TYPE=MyISAM COMMENT='SUPERHERO XP Saving Table';

GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, ALTER ON `sh_savexp` TO np67233_xp;

CREATE TABLE IF NOT EXISTS `sh_saveskills` (
`SH_KEY` varchar(32) binary NOT NULL default '',
`SKILL_NUMBER` tinyint(3) unsigned NOT NULL default '0',
`HERO_NAME` varchar(25) NOT NULL default '',
PRIMARY KEY (`SH_KEY`,`SKILL_NUMBER`)
) TYPE=MyISAM COMMENT='SUPERHERO Skill Saving Table';

GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, ALTER ON `sh_saveskills` TO np67233_xp;

FLUSH PRIVILEGES;

#----------------------------------------------------
# Stop
#----------------------------------------------------
Who can fix that? My database:
sh_mysql_host "localhost"
sh_mysql_user "np67233_xp"
sh_mysql_pass "Bans123"
sh_mysql_db "np67233_xp"
sh_mysql_persistent 0
DOG09 is offline
DOG09
Member
Join Date: Feb 2011
Old 10-19-2013 , 11:33   Re: SuperHero MySQL save
Reply With Quote #6

Quote:
L 10/19/2013 - 181:50: [superheromodmysql.amxx] Exec: (2) Loading shconfig.cfg (message should be seen twice)
[SH] Successfully Loaded Superhero Config File
L 10/19/2013 - 181:50: [superheromodmysql.amxx] DEBUG: Error Making Tables: [1064] 'You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to us' - 'CREATE TABLE IF NOT EXISTS `sh_savexp` ( `SH_KEY` varchar(32) binary NOT NULL default '', `PLAYER_NAME` varchar(32) binary NOT NULL default '', `LAST_PLAY_DATE` timL 10/19/2013 - 181:50: [superheromodmysql.amxx] DEBUG: Couldn't Clean Powers: [1146] 'Table 'user236.sh_saveskills' doesn't exist' - 'DELETE FROM `sh_saveskills` USING `sh_saveskills`, `sh_savexp` WHERE sh_savexp.`SH_KEY` = sh_saveskills.`SH_KEY` AND sh_savexp.`LAST_PLAY_DATE` < (SYSDATE() - INTERVAL '14' DAY) AND NOT (sh_savexp.`HUDHELP` & '4')'
L 10/19/2013 - 181:50: Started map "de_dust2" (CRC "1159425449")

* Privileges set
this is from server....
DOG09 is offline
Krillin
Senior Member
Join Date: Jul 2004
Old 02-10-2014 , 01:06   Re: SuperHero MySQL save
Reply With Quote #7

In the SQL statements where you see
Code:
TYPE=MyISAM
Change them to:
Code:
ENGINE=MyISAM
This should allow SHM to write the tables to the database. This is an old problem with newer MySQL Server Engines 5.0 and above.

Hope this will help you or anyone else. We had to address this problem in 2009!

Best Regards,
Krillin
__________________
Krillin's World Server(s) Operator

Krillin is offline
DOG09
Member
Join Date: Feb 2011
Old 05-03-2014 , 17:23   Re: SuperHero MySQL save
Reply With Quote #8

Thnx, working but now i got new error I did like
12, Close and ReOpen Server.

13, Join server, open console. Type: amx_shvaulttosql << TYPE IT ONLY ONCE!! Don't know why
but if vittu and jtp says so it gotta be right. So there ya go. You have now successfully installed mySQL xp saving.
and then i got error:
Quote:
L 05/04/2014 - 00:21:25: [superheromodmysql.amxx] DEBUG: MySQL connect error: [2002] 'Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)' (,,)
DOG09 is offline
DOG09
Member
Join Date: Feb 2011
Old 05-04-2014 , 07:57   Re: SuperHero MySQL save
Reply With Quote #9

Tried to make manual these tabels but:
Quote:
#1064 - 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 '(6) NOT NULL,
`XP` int(10) NOT NULL default '0',
`HUDHELP` tinyint(6) unsigned' at line 14
DOG09 is offline
DOG09
Member
Join Date: Feb 2011
Old 05-04-2014 , 08:36   Re: SuperHero MySQL save
Reply With Quote #10

My Database server:
Quote:
Server: Localhost via UNIX socket
Server type: MySQL
Server version: 5.5.35-log - MySQL Community Server (GPL)
Protocol version: 10
User: np67233_xp@localhost
Server charset: UTF-8 Unicode (utf
Web server:
Quote:
Apache/2
Database client version: libmysql - 5.5.35
PHP extension: mysqli Documentation
phpMyAdmin:
Quote:
Version information: 4.1.12, latest stable version: 4.1.14
DOG09 is offline
Reply


Thread Tools
Display Modes

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 -4. The time now is 16:54.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode