BeBot - An Anarchy Online and Age Of Conan chat automaton
Archive => Anarchy Online Archive => BeBot 0.2 support => Topic started by: womp on February 09, 2006, 11:16:34 pm
-
I am unable to !member anyone that is not in an org
the error the I get is [2006-02-09 21:56:37] [TELL] [INC] Womp: !member stue
(Incorrect integer value: '' for column 'rank' at row 1)
(Duplicate entry '1630966561' for key 1)
(Duplicate entry '1630966561' for key 1)
[2006-02-09 21:56:38] [TELL] [OUT] -> Womp: Player stue has been added to t
he bot.
[2006-02-09 21:56:38] [TELL] [OUT] -> stue: Womp has added you to the bot.
the member is never added to the table. I have read the post about "Whats the Data type your Rank column in the members table set to? It should be TINYINT." I have checked and that doesnt seem to be the problem either
-
Is the Rank field in your database set to NOT NULL? I suspect it is, as that error is generally only returned when a Null value is being insterted. In the case of a character that are not Org'd the Org Rank and Org Rank Name would be Null values.
I would check to see what fields you have set to NOT NULL. Or you can have mySQL insert a Default value of 0.
Here's a SQL Query you could use to set all that.
alter table `members` ,change `rank` `rank` tinyint (4) DEFAULT '0' NULL
-
I looked through Womp's machine, the only field under the table 'Rank' that is set to NOT NULL is the 'id' field, which I assume contains the numerical FC character ID
I removed the row that contained this character's ID number from the tables 'member_settings' and 'raid_points' since it at least adds those (thus the duplicate error from Womp when we tried adding this user the second time)
I'll look through the php code that does this, maybe I'll find something there :)
-
In the rooter_raid.php I added this right before it added a new member to the DB
if($members["rank"] == NULL)
$members["rank"] = 0;
Seems to work ok for non-guilded people