How do you know if a record exists without doing a READ and CHAIN?
15 pts.
0
Q:
How do you know if a record exists without doing a READ and CHAIN?
How do you know if a record exists without  doing a READ and CHAIN? is it possible with BIF's or ?

Software/Hardware used:
AS/400
ASKED: Sep 7 2009  11:57 AM GMT
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
0
1235 pts.
0
A:
 RATE THIS ANSWER
0
Click to Vote:
  •   0
  •  0
  • AddThis Social Bookmark Button
Hi,
you can use SETLL and equal indicator to a specified record format/file name. If the record exist indicator is on otherwise not .

ORDER SETLLORDFIL 55 PRESNT
N55 GOTO NOTFND

Here if the indicator 55 is on then the record exists.

all the best
Ram


----

Using %BIF


SETLL(e) searchval Recordformat

IF %Equal ;
DSPLY "Yay, found the record";
ENDIF;
Last Answered: Sep 8 2009  2:34 PM GMT by Satsho   1235 pts.
Latest Contributors: Ten2008   730 pts.
0
0
Discuss This Answer:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _



_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

Splat   1050 pts.  |   Sep 9 2009  4:01PM GMT

Nice thing about using SETLL is that it doesn’t load the record buffer, so the operation is faster than using a CHAIN or READ operation.

 
0