NHibernate.Exceptions.GenericADOException
HResult=0x80131600
Message=could not execute query
[ SELECT this_.ID as ID3_0_, this_.Name as Name3_0_, this_.ProfessionReq as Professi3_3_0_, this_.ProficiencyReq as Proficie4_3_0_, this_.LevelReq as LevelReq3_0_, this_.GenderReq as GenderReq3_0_, this_.StrengthReq as Strength7_3_0_, this_.AgilityReq as AgilityReq3_0_, this_.VitalityReq as Vitality9_3_0_, this_.SpiritReq as SpiritReq3_0_, this_.ItemFlags as ItemFlags3_0_, this_.Weight as Weight3_0_, this_.Price as Price3_0_, this_.ActionID as ActionID3_0_, this_.AttackMax as AttackMax3_0_, this_.AttackMin as AttackMin3_0_, this_.DefenseAdd as DefenseAdd3_0_, this_.AccuracyAdd as Accurac18_3_0_, this_.DodgeAdd as DodgeAdd3_0_, this_.HealthAdd as HealthAdd3_0_, this_.ManaAdd as ManaAdd3_0_, this_.Amount as Amount3_0_, this_.AmountMax as AmountMax3_0_, this_.Ident as Ident3_0_, this_.Gem1 as Gem25_3_0_, this_.Gem2 as Gem26_3_0_, this_.Magic1 as Magic27_3_0_, this_.Magic2 as Magic28_3_0_, this_.Magic3 as Magic29_3_0_, this_.MagicAttack as MagicAt30_3_0_, this_.MagicDefense as MagicDe31_3_0_, this_.AttackRange as AttackR32_3_0_, this_.AttackSpeed as AttackS33_3_0_, this_.FrayMode as FrayMode3_0_, this_.RepairMode as RepairMode3_0_, this_.TypeMask as TypeMask3_0_, this_.PriceCP as PriceCP3_0_, this_.TypeDesc as TypeDesc3_0_ FROM itemtype this_ ]
[SQL: SELECT this_.ID as ID3_0_, this_.Name as Name3_0_, this_.ProfessionReq as Professi3_3_0_, this_.ProficiencyReq as Proficie4_3_0_, this_.LevelReq as LevelReq3_0_, this_.GenderReq as GenderReq3_0_, this_.StrengthReq as Strength7_3_0_, this_.AgilityReq as AgilityReq3_0_, this_.VitalityReq as Vitality9_3_0_, this_.SpiritReq as SpiritReq3_0_, this_.ItemFlags as ItemFlags3_0_, this_.Weight as Weight3_0_, this_.Price as Price3_0_, this_.ActionID as ActionID3_0_, this_.AttackMax as AttackMax3_0_, this_.AttackMin as AttackMin3_0_, this_.DefenseAdd as DefenseAdd3_0_, this_.AccuracyAdd as Accurac18_3_0_, this_.DodgeAdd as DodgeAdd3_0_, this_.HealthAdd as HealthAdd3_0_, this_.ManaAdd as ManaAdd3_0_, this_.Amount as Amount3_0_, this_.AmountMax as AmountMax3_0_, this_.Ident as Ident3_0_, this_.Gem1 as Gem25_3_0_, this_.Gem2 as Gem26_3_0_, this_.Magic1 as Magic27_3_0_, this_.Magic2 as Magic28_3_0_, this_.Magic3 as Magic29_3_0_, this_.MagicAttack as MagicAt30_3_0_, this_.MagicDefense as MagicDe31_3_0_, this_.AttackRange as AttackR32_3_0_, this_.AttackSpeed as AttackS33_3_0_, this_.FrayMode as FrayMode3_0_, this_.RepairMode as RepairMode3_0_, this_.TypeMask as TypeMask3_0_, this_.PriceCP as PriceCP3_0_, this_.TypeDesc as TypeDesc3_0_ FROM itemtype this_]
Source=NHibernate
StackTrace:
at NHibernate.Loader.Loader.DoList(ISessionImplementor session, QueryParameters queryParameters)
at NHibernate.Loader.Loader.ListIgnoreQueryCache(ISessionImplementor session, QueryParameters queryParameters)
at NHibernate.Loader.Loader.List(ISessionImplementor session, QueryParameters queryParameters, ISet`1 querySpaces, IType[] resultTypes)
at NHibernate.Loader.Criteria.CriteriaLoader.List(ISessionImplementor session)
at NHibernate.Impl.SessionImpl.List(CriteriaImpl criteria, IList results)
at NHibernate.Impl.CriteriaImpl.List(IList results)
at NHibernate.Impl.CriteriaImpl.List[T]()
at Redux.ControlForm.ReadItemInfoAndCorrectDb() in C:\5017SourceFull1\Redux\ControlForm.cs:line 253
at Redux.ControlForm..ctor() in C:\5017SourceFull1\Redux\ControlForm.cs:line 58
at Redux.Program.Main() in C:\5017SourceFull1\Redux\Program.cs:line 31
This exception was originally thrown at this call stack:
[External Code]
Inner Exception 1:
FormatException: Input string '90000' was not in the correct format.
Inner Exception 2:
OverflowException: Value was either too large or too small for a UInt16.
But why can't it execute the query? Below is the DbItemInfo.hbm.xml in the source
# Name Type Collation Attributes Null Default Comments Extra Action
1 IDPrimary int(4) No None Change Change Drop Drop
More More
2 Name varchar(20) latin1_swedish_ci No None Change Change Drop Drop
More More
3 ProfessionReq smallint(2) No None Change Change Drop Drop
More More
4 ProficiencyReq smallint(2) No None Change Change Drop Drop
More More
5 LevelReq smallint(2) No None Change Change Drop Drop
More More
6 GenderReq tinyint(1) No None Change Change Drop Drop
More More
7 StrengthReq smallint(3) No None Change Change Drop Drop
More More
8 AgilityReq smallint(3) No None Change Change Drop Drop
More More
9 VitalityReq smallint(3) No None Change Change Drop Drop
More More
10 SpiritReq smallint(3) No None Change Change Drop Drop
More More
11 ItemFlags int(4) No None Change Change Drop Drop
More More
12 Weight smallint(2) No None Change Change Drop Drop
More More
13 Price int(4) No None Change Change Drop Drop
More More
14 ActionID int(4) No None Change Change Drop Drop
More More
15 AttackMax smallint(4) No None Change Change Drop Drop
More More
16 AttackMin smallint(4) No None Change Change Drop Drop
More More
17 DefenseAdd smallint(2) No None Change Change Drop Drop
More More
18 AccuracyAdd smallint(2) No None Change Change Drop Drop
More More
19 DodgeAdd smallint(2) No None Change Change Drop Drop
More More
20 HealthAdd smallint(2) No None Change Change Drop Drop
More More
21 ManaAdd smallint(2) No None Change Change Drop Drop
More More
22 Amount int(4) No None Change Change Drop Drop
More More
23 AmountMax int(4) No None Change Change Drop Drop
More More
24 Ident tinyint(1) No None Change Change Drop Drop
More More
25 Gem1 tinyint(1) No None Change Change Drop Drop
More More
26 Gem2 tinyint(1) No None Change Change Drop Drop
More More
27 Magic1 smallint(2) No None Change Change Drop Drop
More More
28 Magic2 smallint(2) No None Change Change Drop Drop
More More
29 Magic3 smallint(2) No None Change Change Drop Drop
More More
30 MagicAttack smallint(2) No None Change Change Drop Drop
More More
31 MagicDefense smallint(2) No None Change Change Drop Drop
More More
32 AttackRange smallint(2) No None Change Change Drop Drop
More More
33 AttackSpeed smallint(2) No None Change Change Drop Drop
More More
34 FrayMode tinyint(1) No None Change Change Drop Drop
More More
35 RepairMode tinyint(1) No None Change Change Drop Drop
More More
36 TypeMask tinyint(2) No None Change Change Drop Drop
More More
37 PriceCP int(4) No None Change Change Drop Drop
More More
38 TypeDesc varchar(32) latin1_swedish_ci No None Change Change Drop Drop
More More
39 Description varchar(512) latin1_swedish_ci No None Change Change Drop Drop
More More
Inner Exception 2:
OverflowException: Value was either too large or too small for a UInt16.
Uint16 (ushort) max value is 65535, you're trying to set 90000.
Simple as that.
I kind of guessed that lol, just no idea where I need to change the 90000. In the source or the database? Because I don't see 90000 any where in the source. I did find 90000 in the database as a price but not sure if it's that or not.
So it turns out it was the price of said items that cause the issue
I kind of guessed that lol, just no idea where I need to change the 90000. In the source or the database? Because I don't see 90000 any where in the source. I did find 90000 in the database as a price but not sure if it's that or not.
So it turns out it was the price of said items that cause the issue
The price on DB is int(4), and on the source its short/ushort? Did you sync your properties after finding out?