diff options
author | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-09-12 18:22:54 +0000 |
---|---|---|
committer | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-09-12 18:22:54 +0000 |
commit | eb7df5bd7ec3557acbe42c17775ffb2cd2e69c36 (patch) | |
tree | 05906bcfcf71133222b7e51f1c145b2707584c5e /src/char_sql | |
parent | 18b8ec2594cd4a8748d8c69a82f61c8637ef400e (diff) | |
download | hercules-eb7df5bd7ec3557acbe42c17775ffb2cd2e69c36.tar.gz hercules-eb7df5bd7ec3557acbe42c17775ffb2cd2e69c36.tar.bz2 hercules-eb7df5bd7ec3557acbe42c17775ffb2cd2e69c36.tar.xz hercules-eb7df5bd7ec3557acbe42c17775ffb2cd2e69c36.zip |
- Added manual deletion of sc_data entries when deleting a character (char-SQL)
- Updated main.sql to use pure MyISAM tables, removed all foreign keys.
- Added Jaguar's sql script to convert all tables to MyISAM. It's located in sql-files/convert_engine.sql
- Removed convert_guild_tables.sql as we don't use InnoDB anymore.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@8722 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/char_sql')
-rw-r--r-- | src/char_sql/char.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/char_sql/char.c b/src/char_sql/char.c index 3a21f2ebb..cb0ebba89 100644 --- a/src/char_sql/char.c +++ b/src/char_sql/char.c @@ -1619,6 +1619,16 @@ int delete_char_sql(int char_id, int partner_id) ShowDebug("at %s:%d - %s\n", __FILE__,__LINE__,tmp_sql);
}
+#ifdef ENABLE_SC_SAVING
+ /* status changes */
+ sprintf(tmp_sql, "DELETE FROM `%s` WHERE `account_id` = '%d' AND `char_id`='%d'",
+ scdata_db, account_id, char_id);
+ if(mysql_query(&mysql_handle, tmp_sql)) {
+ ShowSQL("DB error - %s\n",mysql_error(&mysql_handle));
+ ShowDebug("at %s:%d - %s\n", __FILE__,__LINE__,tmp_sql);
+ }
+#endif
+
if (log_char) {
sprintf(tmp_sql,"INSERT INTO `%s`(`time`, `account_id`,`char_num`,`char_msg`,`name`) VALUES (NOW(), '%d', '%d', 'Deleted char (CID %d)', '%s')",
charlog_db, account_id, 0, char_id, t_name);
|