Kbase P123934: 4GL: GPF invoking the SELECT-PREV-ROW( ) method
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  16/05/2007 |
|
Status: Unverified
FACT(s) (Environment):
HP-UX
OpenEdge 10.1A
SYMPTOM(s):
Code invokes a Browse widget's SELECT-PREV-ROW( ) method using code similar to:
DEFINE VARIABLE rNextRow AS ROWID NO-UNDO
IF BROWSE BrowseName:SELECT-NEXT-ROW() THEN
rNext = rowid(tt-pro).
ELSE
IF BROWSE BrowseName:SELECT-PREV-ROW() THEN
rNextRow = rowid(tt-pro).
ELSE
rNextRow = ?.
Problem can not be reproduced in isolation of running the code within a large application.
Stack trace includes:
uttraceback + 0x60 [/usr1/dlc101a/bin/_progres]
utcore + 0x3a0 [/usr1/dlc101a/bin/_progres]
drexit + 0x650 [/usr1/dlc101a/bin/_progres]
drSigFatal + 0x90 [/usr1/dlc101a/bin/_progres]
_user_sendsig + 0x2620 [***_Kernel_Gateway_***]
umBrowseGetAttr + 0xa6e0 [/usr1/dlc101a/bin/_progres]
umFldClassGetAttr + 0x1280 [/usr1/dlc101a/bin/_progres]
umSuperGetAttr + 0x1b70 [/usr1/dlc101a/bin/_progres]
ioGetAttribute + 0x140 [/usr1/dlc101a/bin/_progres]
fmEWDAX + 0x710 [/usr1/dlc101a/bin/_progres]
fmeval + 0x610 [/usr1/dlc101a/bin/_progres]
rnexfm + 0x120 [/usr1/dlc101a/bin/_progres]
rnifstmt + 0x140 [/usr1/dlc101a/bin/_progres]
rnexec_entry + 0x960 [/usr1/dlc101a/bin/_progres]
rninterpret + 0x1b0 [/usr1/dlc101a/bin/_progres]
umeDispatchEvent + 0x10a0 [/usr1/dlc101a/bin/_progres]
wvRunDispatcher + 0x930 [/usr1/dlc101a/bin/_progres]
iodispatch + 0x110 [/usr1/dlc101a/bin/_progres]
rnrq + 0x100 [/usr1/dlc101a/bin/_progres]
main + 0x5c0 [/usr1/dlc101a/bin/_progres]
main_opd_entry + 0x50 [/usr/lib/hpux64/dld.so]
FIX:
Use the GET-NEXT() and GET-PREV() Query methods or the REPOSITION-FORWARD() and REPOSITION-BACKWORD() Query methods to achieve the same functionality. For example:
A. Using the GET-NEXT() and GET-PREV() Query methods:
DEFINE VARIABLE rNextRow AS ROWID NO-UNDO.
DEFINE VARIABLE lResult AS LOGICAL NO-UNDO.
ASSIGN
rNextRow = ?
lResult = ?.
lResult = QueryName:GET-NEXT(NO-LOCK) NO-ERROR.
IF lResult THEN
ASSIGN
rNextRow = ROWID(TableName).
ELSE
lResult = QueryName:GET-PREV(NO-LOCK) NO-ERROR.
IF lResult THEN
ASSIGN
rNextRow = ROWID(TableName).
B. Using the REPOSITION-FORWARD() and REPOSITION-BACKWORD() Query methods:
DEFINE VARIABLE rNextRow AS ROWID NO-UNDO.
DEFINE VARIABLE lResult AS LOGICAL NO-UNDO.
ASSIGN
rNextRow = ?
lResult = ?
lResult = QueryName:REPOSITION-FORWARD(1)NO-ERROR.
IF lResult THEN
ASSIGN
rNextRow = ROWID(TableName).
ELSE
lResult = QueryName:REPOSITION-BACKWARD(1)NO-ERROR.
IF lResult THEN
ASSIGN
rNextRow = ROWID(TableName).