cancel
Showing results for 
Search instead for 
Did you mean: 

An error occurred within the Unity API: Value was either too large or too small for an Int6

Yossi_Eli
Champ in-the-making
Champ in-the-making

This is a very unhelpful message. 

Any ideas what generates this error?

I am getting this error at the point of trying to store a document. I had Unity API V16 and I must say that it started appearing after moving to V16 from V15.

Any ideas?

Thanks.

1 ACCEPTED ANSWER

Joe_Kocsis
Confirmed Champ
Confirmed Champ

Yossi,

In the OnBase database, The Numeric9 keyword type is mapped to a BigInt SQL datatype and Numeric20 keyword type is mapped to a decimal SQL datatype.  In the .NET world these are a Long and Decimal dataypes, respectively.  This would cause you to encounter this error if you are creating an int16 type. If you look in the SDK under: Accessing Keywords in Keyword Records, you will see a switch statement which shows which .NET datatypes are used for various KW types.  You can also refer to this page: https://msdn.microsoft.com/en-us/library/cc716729(v=vs.110).aspx  which shows which .NET datatypes match to which SQL datatypes.

View answer in original post

2 REPLIES 2

Scott_Poti1
Star Contributor
Star Contributor
Sounds like it didn't like one of the keyword values on the document you are storing.

Joe_Kocsis
Confirmed Champ
Confirmed Champ

Yossi,

In the OnBase database, The Numeric9 keyword type is mapped to a BigInt SQL datatype and Numeric20 keyword type is mapped to a decimal SQL datatype.  In the .NET world these are a Long and Decimal dataypes, respectively.  This would cause you to encounter this error if you are creating an int16 type. If you look in the SDK under: Accessing Keywords in Keyword Records, you will see a switch statement which shows which .NET datatypes are used for various KW types.  You can also refer to this page: https://msdn.microsoft.com/en-us/library/cc716729(v=vs.110).aspx  which shows which .NET datatypes match to which SQL datatypes.