Kbase P95764: Dyn 2.1A03: FindRowWhere returns YES when no record to find and repositions to unexpected row
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  10/13/2004 |
|
Status: Unverified
FACT(s) (Environment):
Dynamic 2.1A
NEGATED FACT(s) Environment):
OpenEdge 10.0B
SYMPTOM(s):
Dynamics 2.1A03
FindRowWhere returns YES when it does not find the wanted record
The dataSource SDO is also repositioned to an unexpected row
RunTime session type (appServer)
CHANGE:
Applied service pack 3 (2.1A03)
CHANGE:
RunTime session type (it works OK with DB bound session)
CAUSE:
Known Regression in 2.1A03 (not in 10.0B). In a thin client session, fetchRowWhere now returns YES when no record can be found on the AppServer. Because of that, the findRowWhere API also returns yes and reposition the dataSource to an unexpected record.
FIX:
Instead of findRowWhere, you can use rowidWhereCols (same parameters as findRowWehere) then call fetchRowIdent if rowidWhereCols does not return unknown value. Unlike with findRowWhere, this solution does not try to first find the record on the client side. it always goes to the AppServer side.
<pre>DEF VAR cRowids AS CHAR NO UNDO.
{get DataSource hDataSource}.
cValue = widgetValue("cValue").
cRowids = DYNAMIC-FUNCTION('RowidWhereCols':U IN hDataSource
,"customer_code"
,cValue
,"").
IF cRowIds = ? THEN RETURN NO.
DYNAMIC-FUNCTION('fetchRowIdent':U IN hDataSource , cRowIds , ?).</pre>