I have a program which imports about 250 000 records which updates the database while doing so. I have different includes and external procedures in this program, but none of them have a definition for a temp table - it has been moved to the main programs definition section. I got the error on about 40 000 records and after copying code into the main program from the includes and external procedures the error moved to record 121 658.
Can anyone please assist me with this problem.
I defined the temp table with no-undo. Did not made a difference.
Are you calling an external procedure instead of an internal procedure where the main code lives? Your example isn't clear, please provide more information.
I think there are several options you could try:
1) create transaction batches instead of doing one big transaction of 250.000 rows
(create a transaction loop that processes 100 rows or so)
2) are you calling a non-persistent external procedure, thereby passing the temp-table as a parameter? If so, you might want to try moving that logic into an internal procedure of the main procedure.
3) are you passing the temp-table by value or by reference? You should do the latter, else you get a new copy on every call.
4) if nothing helps, try passing the buffer or the temp-table handle and use the dynamic API to work against the handle. This assures you're passing the object by reference.
Did you have a look at http://progress.atgnow.com/esprogress/Group.jsp?bgroup=progress&id=P112397
There is another link towards the bottom which describes a method of detecting stray TT's which can result of the auto-create of TT's. May be worth throwing this in a call around record number 5000 and see if anything pops up.
Did you have a look at
http://progress.atgnow.com/esprogress/Group.jsp?bgroup
=progress&id=P112397
There is another link towards the bottom which
describes a method of detecting stray TT's which can
result of the auto-create of TT's. May be worth
throwing this in a call around record number 5000 and
see if anything pops up.
O, yeah, not deleting the temp-table handle for static temp-table by-value parameters is pitfall # 1... Very intuitive, he, he....