Pages: [1] :: one page |
|
Author |
Thread Statistics | Show CCP posts - 0 post(s) |
Buliki
Brutor Tribe Minmatar Republic
10
|
Posted - 2016.07.06 21:13:09 -
[1] - Quote
I have about 14 skills which have two different values for valueInt & valueFloat
An example:
dmgtypeattributes
typeID 19922 has attribute 277 (requiredSkill1Level) set to valueInt 5 and valueFloat 4.
Which one has precedence over the other ?
Also if you can explain to me how this system works, because right now I'm using valueInt+valueFloat which gave me required level 9... Would not have been better if I were to test for one or the other because they both have a value... I'm a bit lost
Thank you |
Captain Thunk
Explode. Now. Please. Alliance. Now. Please.
192
|
Posted - 2016.07.06 23:29:55 -
[2] - Quote
There is no specific precedence, the chosen attribute value can be either float or integer, there's no discernible pattern to it and can frequently change between items - values that can only ever be integers might use float anyway. In general, it's best to use 'SELECT COALESCE(valueFloat,valueInt) AS value' in your queries.
As to your question, the one you want to use is valueInt - I'm using an older DB conversion and there is no valueFloat used in your example.
It could be CCP or it could be an error in the conversion with what you're using (Unless you're using CREST, you don't specify the source) |
Buliki
Brutor Tribe Minmatar Republic
10
|
Posted - 2016.07.07 04:47:37 -
[3] - Quote
Thanks for your input Captain.
I'm using Steve's export simply imported into my database. I should not have changed anything while importing.
I have about 14 skills which are like that and they look like skills that might have changed last patch so it looks like an error.
I believe COALESCE would have given the answer 9 as well
I think I'll use if valueInt AND valueFloat use valueInt. |
Mr Mac
Dark Goliath
158
|
Posted - 2016.07.07 05:24:27 -
[4] - Quote
Level value always be int then use valueInt.
Coalesce (int, float). I believe it will return all 14 answers. If both expressions are not null and returns first expression (in this case, int). I cant check im not at comp :( |
|
|
|
Pages: [1] :: one page |
First page | Previous page | Next page | Last page |