DAVID WADEMAN wrote:
> Is there the ID of GM.SHF in GM.GMF file? If so then you could used:
>
>> ED DICT GM.GMF TURNS
> 0001: I
> 0002: SUBR('*CALC.TURNS',GMF.SHF.ID)
Jeff's originally attempted
TRANS(GM.SHF,SMF.LINK,TURNS,'X')
implies that DICT GM.GMF SMF.LINK is the foreign key to the
corresponding GM.SHF record.
That's why I said that the proper I descriptor will be
DICT GM.GMF TURNS
01: I
02: CALL( '*CALC.TURNS', SMF.LINK )
That assumes that CALC.TURNS doesn't do something like assume @RECORD
contains the current GM.SHF record.
If it does, it will need to be altered to pass the record as an
argument, instead/
Then you'd use it in 2 I-descriptors as:
DICT GM.SHF TURNS
01: I
02: SUBR( '*CALC.TURNS', @ID, @RECORD )
DICT GM.GMF TURNS
01: I
02: SUBR( '*CALC.TURNS', SMF.LINK, RAISE(TRANS( GM.SHF, SMF.LINK,
-1,'X')))
The "-1" trans arg means return the whole record.
The RAISE() is because TRANS() automatically lowers all delimiters a
notch. (Why that is, is for another thread.)
_______________________________________________
U2-Users mailing list
[email protected]
http://listserver.u2ug.org/mailman/listinfo/u2-users