Consultor Eletrônico



Kbase P156757: NUM-RESULTS function returns ? when used against a query defined for a ProDataSet
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   02/12/2009
Status: Unverified

SYMPTOM(s):

NUM-RESULTS function returns ? when used against a query defined for a ProDataSet

Result does not change whether the function is placed before or after the FILL method

Result does not change whether the function is placed in a BEFORE-FILL callback event

Result does not change whether the function is placed in an AFTER-FILL callback event

Correct number of records are returned if the function is place in a BEFORE-ROW-FILL callback event

Correct number of records are returned if the function is place in an AFTER-ROW-FILL callback event

FACT(s) (Environment):

ProDataSet Temp-table(s) is populated as expected
Query is defined as SCROLLING
OpenEdge 10.x
All Supported Operating Systems

CAUSE:

This is expected behaviour. A query for filling a ProDataSet is opened after the BEFORE-FILL callback event has fired, and closed before the AFTER-FILL callback event has fired. NUM-RESULTS will return unknown (?) if the query is not open.

FIX:

Use a BEFORE-ROW-FILL or AFTER-ROW-FILL callback event to obtain a value from the NUM-RESULTS function. Be aware that the callback event will be called for each row added.