CREATE TABLE IF NOT EXISTS `player_inboxitems`
(
`player_id` INTEGER NOT NULL,
`sid` INTEGER NOT NULL,
`pid` INTEGER NOT NULL DEFAULT 0,
`itemtype` SMALLINT NOT NULL,
`count` SMALLINT NOT NULL DEFAULT 0,
`attributes` BLOB NOT NULL,
UNIQUE (`player_id`,`sid`),
PRIMARY KEY (`player_id`),
FOREIGN KEY (`player_id`) REFERENCES `players`(`id`) ON DELETE CASCADE
);