Home
Help
Register
Log in

Search

 
   Active Threads  

You are here: Home > LLBLGen Pro > Bugs & Issues> The value specified will cause an overflow error in the database.
 

Pages: 1
Bugs & Issues
The value specified will cause an overflow error in the database.
Page:1/1 

  Print all messages in this thread  
Poster Message
MattSeaboard
User



Location:
Kansas City, MO
Joined on:
07-Jun-2016 20:49:49
Posted:
24 posts
# Posted on: 12-Jun-2020 23:49:15.  
LLBLGen version 2.6

we recently increased a column from 5 characters to 20 and we get the following error when trying to insert a 6 character value:

The value specified will cause an overflow error in the database. Value length: 6. Column max. length: 5
Parameter name: Htank01.

After regenerating I see this metadata on that property in our Domain project:

        ''' <summary>The Htank01 property of the Entity TblGrossmanOrotrn<br/><br/>
        ''' </summary>
        ''' <remarks>
        ''' Mapped on table field: "tblGrossman_Orotrn"."HTank01"<br/>
        ''' Table field type characteristics (type, precision, scale, length): Char, 0, 0, 20<br/>
        ''' Table field behavior characteristics (is nullable, is PK, is identity): True, False, False
        ''' </remarks>

It clearly shows that the length is now 20 but our code is still erroring.

Any assistance?
  Top
daelmo
Support Team



Location:
Guatemala City
Joined on:
28-Nov-2005 23:35:24
Posted:
8138 posts
# Posted on: 14-Jun-2020 07:15:24.  
If you get the error before re-generating: the error makes sense, as the framework sees the 5 length. If you re-generated and still get the error, please double check that you are using the correct generated code.

If it persists, please post the exception message and stack trace. Also your LLBLGen runtime library version (https://www.llblgen.com/TinyForum/Messages.aspx?ThreadID=7717) .


David Elizondo
LLBLGen'ing (articles and code snippets) | linkedin | twitter
 
Top
MattSeaboard
User



Location:
Kansas City, MO
Joined on:
07-Jun-2016 20:49:49
Posted:
24 posts
# Posted on: 15-Jun-2020 17:21:22.  
Version is 2.6 Final.

This was AFTER regenerating.

I got the error to go away for some fields by unmapping the field, regenerating, then remapping the field and regenerating again.

I'm still having an issue with one field not recognizing the field size increase from 5 to 20.
  Top
MattSeaboard
User



Location:
Kansas City, MO
Joined on:
07-Jun-2016 20:49:49
Posted:
24 posts
# Posted on: 15-Jun-2020 20:26:45.  
Finally resolved this by deleting the domain project entirely and regenerating from scratch.

Not sure why LLBLGen was refusing to accept the new fieldsize Confused but this is resolved now.


  Top
Otis
LLBLGen Pro Team



Location:
The Hague, The Netherlands
Joined on:
17-Aug-2003 18:00:36
Posted:
38047 posts
# Posted on: 16-Jun-2020 07:54:50.  
It might have been because a file was locked/readonly and therefore not overwritten. Although 2.6 is 12 years old it did produce a log afterwards where it would describe these events. But anyway, that's for next time, glad it's solved now Regular Smiley
Frans Bouma
LLBLGen Pro / ORM Profiler Lead Developer | Blog | Twitter
 
Top
Pages: 1  


Powered by HnD ©2002-2007 Solutions Design
HnD uses LLBLGen Pro

Version: 2.1.12172008 Final.