Besides the views (I have 5 - 2 bots ones, groups, and guilds, plus 1 for mercs), there are also 2 routines, which, by the sound of it, should be included with --routines. Make sure they are added before the view creation. They are:
Code:
delimiter $$
CREATE DEFINER=`root`@`localhost` FUNCTION `GetMobTypeById`(mobid INTEGER UNSIGNED) RETURNS char(1) CHARSET utf8
BEGIN
DECLARE Result CHAR(1);
SET Result = NULL;
IF (select id from character_ where id = mobid) > 0 THEN
SET Result = 'C';
ELSEIF (select BotID from bots where BotID = mobid) > 0 THEN
SET Result = 'B';
END IF;
RETURN Result;
END$$
and
Code:
delimiter $$
CREATE DEFINER=`root`@`localhost` FUNCTION `GetMobTypeByName`(mobname VARCHAR(64)) RETURNS char(1) CHARSET utf8
BEGIN
DECLARE Result CHAR(1);
SET Result = NULL;
IF (select id from character_ where name = mobname) > 0 THEN
SET Result = 'C';
ELSEIF (select BotID from bots where Name = mobname) > 0 THEN
SET Result = 'B';
END IF;
RETURN Result;
END$$