We have problem with loading all very big Int64 values from server to client. I think problem is for all numbers larger then 25776087313154050.
We using No DB approach of Breeze and makes all metadata manually. Here is metadata:
store.addEntityType({
shortName: "AdditionalInfoType",
namespace: "Services",
autoGeneratedKeyType: breeze.AutoGeneratedKeyType.Identity,
dataProperties: {
id: {dataType: breeze.DataType.Int64, isNullable: false, isPartOfKey: true },
name: { dataType: breeze.DataType.String, isNullable: true },
dataType: { dataType: breeze.DataType.String, isNullable: false, defaultValue: 'Unknown' }
},
navigationProperties: {
enumItems: {
entityTypeName: "AdditionalInfoEnumValue", isScalar: false, associationName: "AdditionalInfoEnumValue_AdditionalInfoType"
}
}
});
Here is what Fiddler showing from server (data is correct here):
[{"$id":"1","$type":"Services.AdditionalInfoType, Services",
"Name":"Shoe Size","DataType":"Numeric","EnumItems":null,"Id":25776087313154051},
{"$id":"2","$type":"Services.AdditionalInfoType, Services",
"Name":"Floating Holiday","DataType":"Date","EnumItems":null,"Id":25776087313154050}]
Breeze query is pretty simple:
entityQuery.from('AdditionalInfoTypes')
.toType(entityNames.additionalInfoType)
.using(employeeManager)
And here what we have in client (unfortunately I can not post images here):
entity[0].id == 25776087313154052
entity[1].id == 25776087313154050
So, Id for second entity correctly loads and have value: 25776087313154050
for both client and server. But for 25776087313154051
server value on client its 25776087313154052
.
I did some experiments and found that problem reproducable for all numbers > 25776087313154050 (for both Key part and not). Every time breeze loader increase number by 1.
Any ideas where me wrong or how to solve it?