Subject RE: [IBO] Value out of range error when inserting into a table
Author Terry Black
Hi Jason, I have found the problem - my fault. The primary key is a small int data range -32768 - 32767 and I was trying to add 100,000 records. No wonder it gave me 'Value out of range'


IT Manager | Public Health Unit Hornsby | Northern Sydney Local Health District
Hornsby Hospital, Main Building 1, 36-76 Palmerston Road, Hornsby NSW 2077
Tel. 02 9477 9400 | Fax. 02 9482 1650 | tblac@...

>>> "IBO Support List" <supportlist@...> 10/04/2013 9:19 am >>>
I think a bit more information would be helpful. I'm not sure what to advise
you at this point. You don't specify in what manner you have a generator on
the primary key. If it is in the trigger then the client will not be aware
of it in some cases.


-----Original Message-----
From: [] On Behalf
Of Terry Black
Sent: Tuesday, April 9, 2013 4:43 PM
Subject: [IBO] Value out of range error when inserting into a table

Hi, I am inserting records into a table using a for loop

For j := 1 to 10000 do
qrMain.FieldByName('Team').value := 'xxx';

This is a simple for loop to add 10000 new records, however, I am getting an
exception class EIB_ColumnError with message 'Value out of range'.

I have a generator on the primary key.




IB Objects - direct, complete, custom connectivity to Firebird or InterBase
without the need for BDE, ODBC or any other layer.
___________________________________________________________________________ - your IBO community resource for Tech Info papers,
keyword-searchable FAQ, community code contributions and more !
Yahoo! Groups Links

Disclaimer: This message is intended for the addressee named and may contain confidential information. If you are not the intended recipient, please delete it and notify the sender.

Views expressed in this message are those of the individual sender, and are not necessarily the views of the Local Health District or associated entities.