Consultor Eletrônico



Kbase 16812: Error 3307 - Internal Procedures and Action Code Segments
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   6/4/2010
Status: Verified

SYMPTOM(s):

Error 3307 - Internal Procedures and Action Code Segments

<segment-name> has exceeded its limit of <segment-size> bytes, in <file-name> at line # <line-number>. (3307)

FACT(s) (Environment):

Progress Version 8.x
Progress Version 9.x
OpenEdge 10.x
All Supported Operating Systems
OpenEdge Category: Language (4GL/ABL)

CAUSE:

When certain code structures are placed in an Internal Procedure, they cause the Main Block's Action segment to get bigger. Users may encounter error 3307 - Action Segment has exceeded its limit of 62K.

FIX:

Any trigger block gets registered with the main procedure (and thus takes up 40 bytes in the main procedure's action code segment). This is necessary for setting up slots for program variables defined inside the triggers (which happens at .p startup time).

Doing a find of a record from a buffer not in the current record scope increases the Action segment by 24 bytes. This is from the establishment of a cursor on the procedure block of the main .p (and thus the action cell segment of the main .p). Since the buffer is not explicitly defined in the internal procedure, Progress assumes that it is scoped to the main procedure. Since it's scoped to the main procedure, and there's a FIND statement in an internal procedure (or trigger) which could be executed at an indeterminate time, we need to establish the cursor somewhere and it makes the most sense to establish it at the main procedure block. This is so you can do the following:

FORM WITH FRAME x.
RUN foo IN THIS-PROCEDURE.
RUN foo IN THIS-PROCEDURE.
RUN foo IN THIS-PROCEDURE.

PROCEDURE foo:
FIND NEXT customer.
DISPLAY customer WITH FRAME x.
END.

and you will see customers 1, 2, and 3. If the cursor were *not* established at the main .p procedure (where the buffer is scoped), you'd see customer 1, three times, since the cursor would be re-established each time you called foo.

Progress releases 9.1C through 9.1E support up to four main action code segments (62K for each segment) for the main procedure, and continues to support one separate action code segment for each internal procedure.

Starting with OpenEdge 10, maximum size for the action code segments is increased to approximately 4MB.