diff --git a/sql/base/realmd.sql b/sql/base/realmd.sql index 58b0ba8e5e5..c34cadc00e4 100644 --- a/sql/base/realmd.sql +++ b/sql/base/realmd.sql @@ -21,7 +21,7 @@ DROP TABLE IF EXISTS `realmd_db_version`; CREATE TABLE `realmd_db_version` ( - `required_14064_01_realmd_platform` bit(1) DEFAULT NULL + `required_14083_01_realmd_joindate_datetime` bit(1) DEFAULT NULL ) ENGINE=MyISAM DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC COMMENT='Last applied sql update to DB'; -- @@ -48,7 +48,7 @@ CREATE TABLE `account` ( `v` longtext, `s` longtext, `email` text, - `joindate` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, + `joindate` DATETIME NOT NULL DEFAULT NOW(), `lockedIp` varchar(30) NOT NULL DEFAULT '0.0.0.0', `failed_logins` int(11) unsigned NOT NULL DEFAULT '0', `locked` tinyint(3) unsigned NOT NULL DEFAULT '0', diff --git a/sql/updates/realmd/14083_01_realmd_joindate_datetime.sql b/sql/updates/realmd/14083_01_realmd_joindate_datetime.sql new file mode 100644 index 00000000000..4368e082cff --- /dev/null +++ b/sql/updates/realmd/14083_01_realmd_joindate_datetime.sql @@ -0,0 +1,5 @@ +ALTER TABLE realmd_db_version CHANGE COLUMN required_14064_01_realmd_platform required_14083_01_realmd_joindate_datetime bit; + +ALTER TABLE `account` MODIFY joindate DATETIME NOT NULL DEFAULT NOW(); + + diff --git a/src/shared/revision_sql.h b/src/shared/revision_sql.h index 6f73e939627..7b3e9c5d09a 100644 --- a/src/shared/revision_sql.h +++ b/src/shared/revision_sql.h @@ -1,6 +1,6 @@ #ifndef __REVISION_SQL_H__ #define __REVISION_SQL_H__ - #define REVISION_DB_REALMD "required_14064_01_realmd_platform" + #define REVISION_DB_REALMD "required_14083_01_realmd_joindate_datetime" #define REVISION_DB_LOGS "required_14039_01_logs_anticheat" #define REVISION_DB_CHARACTERS "required_14061_01_characters_fishingSteps" #define REVISION_DB_MANGOS "required_14082_01_mangos_spell_template"