Jump to content

  •  

Bug Tracker Migration

June 3rd
Good news everyone! The staff has decided that it is time to slowly kill off this Bug Tracker. We will begin the process of slowly migrating from this Bug Tracker over to our Github Issues which can be found here: https://github.com/HerculesWS/Hercules/issues

Over the next couple of days, I will be closing off any opportunity to create new reports. However, I still will keep the opportunity to reply to existing Bug Reports. Doing this will allow us to slowly fix any bug reports we have listed here so that we can easily migrate over to our Issue Tracker.

Update - June 7th 2015: Creating new bug posts has been disabled. Please use our https://github.com/HerculesWS/Hercules/issues tracker to post bugs. Users are still able to reply to existing bug posts.

- Administration

Issue Information

  • #007854

  • 0 - None Assigned

  • Fixed

Issue Confirmations

  • Yes (0)No (0)
Photo

SQL Table "inventory" got the wrong typ

Posted by Vincent on 25 November 2013 - 03:56 PM

I get sometimes a Error at the Console because of the Colum "favorite" at the "inventory" Table.

At the main.sql favorite is:
`favorite` tinyint(3) unsigned NOT NULL default '0',
my suggestion make it to a normal int(10).

Error:
[SQL]: DB error - Out of range value for column 'favorite' at row 1
[Debug]: at ..\src\char\char.c:986 - INSERT INTO `inventory` (`char_id`, `nameid`, `amount`, `equip`, `identify`, `refine`, `attribute`, `expire_time`, `favorite`, `bound`, `unique_id`, `card0`, `card1`, `card2`, `card3`) VALUES ('150003','2268', '1', '0', '1', '0', '0', '0', '-31', '0', '0', '0', '0', '0', '0'

Ind 
changed status to: Working as Intended

favorite is a flag that stores a 1/0 value, if you're getting higher or lower values I'd guess you have some custom code that is setting the value unproperly (or failing to set which would cause the var to use garbage memory)

favorite is a flag that stores a 1/0 value, if you're getting higher or lower values I'd guess you have some custom code that is setting the value unproperly (or failing to set which would cause the var to use garbage memory)

Can You telll me where the source code for setting this var is?!

Spoke with ind on irc about this too.
We shouldn't have any custom code for that. Only non skill based custom src change we have is Battleground only usable mats (working fine and shouldnt have anything to do with favorite).
Check the sql tables if there are "favorites" set to other than 0/1, maybe they got corrupted in the sql table converion from rA to Hercules.
I guess this is just an issue only we are having (+possibly others who converted from rA to Hercules).


Edit: k, so nothing wrong with sql tables everything 0/1 like it should be. this is randomly happening with normal items when vended or traded.
inventory_to_sql trying to give favorite strage values. randomness is what mostly bothers me, working fine most of the times.
Someone should move this to source/database support if this is only us.

Edited by GrumpyPanda, 26 November 2013 - 01:29 PM.


changed status to: Fixed

There was an issue that could potentially cause this, as I mentioned in irc yesterday. It's now fixed in https://github.com/H...3e606d658682136