1
0
Fork 0

RankMgr: Added SQL integer datatypes.

This commit is contained in:
madmaxoft 2014-08-05 22:32:26 +02:00
parent fcfae02525
commit a717a7e712
1 changed files with 5 additions and 5 deletions

View File

@ -70,11 +70,11 @@ cRankManager::cRankManager(void) :
m_DB("Ranks.sqlite", SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE)
{
// Create the DB tables, if they don't exist:
m_DB.exec("CREATE TABLE IF NOT EXISTS Rank (RankID, Name, MsgPrefix, MsgPostfix, MsgNameColorCode)");
m_DB.exec("CREATE TABLE IF NOT EXISTS PlayerRank (PlayerUUID, PlayerName, RankID)");
m_DB.exec("CREATE TABLE IF NOT EXISTS PermissionGroup (GroupID, Name)");
m_DB.exec("CREATE TABLE IF NOT EXISTS RankPermissionGroups (RankID, GroupID)");
m_DB.exec("CREATE TABLE IF NOT EXISTS PermissionItem (GroupID, Permission)");
m_DB.exec("CREATE TABLE IF NOT EXISTS Rank (RankID INTEGER PRIMARY KEY, Name, MsgPrefix, MsgPostfix, MsgNameColorCode)");
m_DB.exec("CREATE TABLE IF NOT EXISTS PlayerRank (PlayerUUID, PlayerName, RankID INTEGER)");
m_DB.exec("CREATE TABLE IF NOT EXISTS PermissionGroup (GroupID INTEGER PRIMARY KEY, Name)");
m_DB.exec("CREATE TABLE IF NOT EXISTS RankPermissionGroups (RankID INTEGER, GroupID INTEGER)");
m_DB.exec("CREATE TABLE IF NOT EXISTS PermissionItem (GroupID INTEGER, Permission)");
// TODO: Check if tables empty, add some defaults then
}