CREATE TABLE lb_characters
(
    id                   INT              NOT NULL AUTO_INCREMENT,
    accountid            INT              NOT NULL DEFAULT '0',
    world                INT              NOT NULL DEFAULT '0',
    `name`               VARCHAR(13)      NOT NULL DEFAULT '',
    level                INT              NOT NULL DEFAULT '1',
    exp                  INT              NOT NULL DEFAULT '0',
    gachaexp             INT              NOT NULL DEFAULT '0',
    str                  INT              NOT NULL DEFAULT '12',
    dex                  INT              NOT NULL DEFAULT '5',
    luk                  INT              NOT NULL DEFAULT '4',
    `int`                INT              NOT NULL DEFAULT '4',
    hp                   INT              NOT NULL DEFAULT '50',
    mp                   INT              NOT NULL DEFAULT '5',
    maxhp                INT              NOT NULL DEFAULT '50',
    maxmp                INT              NOT NULL DEFAULT '5',
    meso                 INT              NOT NULL DEFAULT '0',
    hpMpUsed             INT UNSIGNED     NOT NULL DEFAULT '0',
    job                  INT              NOT NULL DEFAULT '0',
    skincolor            INT              NOT NULL DEFAULT '0',
    gender               INT              NOT NULL DEFAULT '0',
    fame                 INT              NOT NULL DEFAULT '0',
    fquest               INT              NOT NULL DEFAULT '0',
    hair                 INT              NOT NULL DEFAULT '0',
    face                 INT              NOT NULL DEFAULT '0',
    ap                   INT              NOT NULL DEFAULT '0',
    sp                   VARCHAR(128)     NOT NULL DEFAULT '0,0,0,0,0,0,0,0,0,0',
    map                  INT              NOT NULL DEFAULT '0',
    spawnpoint           INT              NOT NULL DEFAULT '0',
    gm                   TINYINT          NOT NULL DEFAULT '0',
    party                INT              NOT NULL DEFAULT '0',
    buddyCapacity        INT              NOT NULL DEFAULT '25',
    createdate           TIMESTAMP        NOT NULL DEFAULT CURRENT_TIMESTAMP,
    `rank`               INT UNSIGNED     NOT NULL DEFAULT '1',
    rankMove             INT              NOT NULL DEFAULT '0',
    jobRank              INT UNSIGNED     NOT NULL DEFAULT '1',
    jobRankMove          INT              NOT NULL DEFAULT '0',
    guildid              INT UNSIGNED     NOT NULL DEFAULT '0',
    guildrank            INT UNSIGNED     NOT NULL DEFAULT '5',
    messengerid          INT UNSIGNED     NOT NULL DEFAULT '0',
    messengerposition    INT UNSIGNED     NOT NULL DEFAULT '4',
    mountlevel           INT              NOT NULL DEFAULT '1',
    mountexp             INT              NOT NULL DEFAULT '0',
    mounttiredness       INT              NOT NULL DEFAULT '0',
    omokwins             INT              NOT NULL DEFAULT '0',
    omoklosses           INT              NOT NULL DEFAULT '0',
    omokties             INT              NOT NULL DEFAULT '0',
    matchcardwins        INT              NOT NULL DEFAULT '0',
    matchcardlosses      INT              NOT NULL DEFAULT '0',
    matchcardties        INT              NOT NULL DEFAULT '0',
    MerchantMesos        INT                       DEFAULT '0',
    HasMerchant          TINYINT                   DEFAULT '0',
    equipslots           INT              NOT NULL DEFAULT '24',
    useslots             INT              NOT NULL DEFAULT '24',
    setupslots           INT              NOT NULL DEFAULT '24',
    etcslots             INT              NOT NULL DEFAULT '24',
    familyId             INT              NOT NULL DEFAULT '-1',
    monsterbookcover     INT              NOT NULL DEFAULT '0',
    allianceRank         INT              NOT NULL DEFAULT '5',
    vanquisherStage      INT UNSIGNED     NOT NULL DEFAULT '0',
    ariantPoints         INT UNSIGNED     NOT NULL DEFAULT '0',
    dojoPoints           INT UNSIGNED     NOT NULL DEFAULT '0',
    lastDojoStage        INT UNSIGNED     NOT NULL DEFAULT '0',
    finishedDojoTutorial TINYINT UNSIGNED NOT NULL DEFAULT '0',
    vanquisherKills      INT UNSIGNED     NOT NULL DEFAULT '0',
    summonValue          INT UNSIGNED     NOT NULL DEFAULT '0',
    partnerId            INT              NOT NULL DEFAULT '0',
    marriageItemId       INT              NOT NULL DEFAULT '0',
    reborns              INT              NOT NULL DEFAULT '0',
    PQPoints             INT              NOT NULL DEFAULT '0',
    dataString           VARCHAR(64)      NOT NULL DEFAULT '',
    lastLogoutTime       TIMESTAMP        NOT NULL DEFAULT '2015-01-01 05:00:00',
    lastExpGainTime      TIMESTAMP        NOT NULL DEFAULT '2015-01-01 05:00:00',
    partySearch          TINYINT          NOT NULL DEFAULT '1',
    jailexpire           BIGINT           NOT NULL DEFAULT '0',
    PRIMARY KEY (id),
    KEY accountid (accountid),
    KEY party (party),
    KEY ranking1 (`level`, exp),
    KEY ranking2 (gm, job),
    INDEX (id, accountid, world),
    INDEX (id, accountid, `name`)
);