USE ss IN 0 ALIAS ss
fun(0)
fun(1)
fun(2)
SELECT * FROM ss
USE IN "ss"
RETURN
FUNCTION fun(n)
cn = TRANSFORM(n)
USE ("s"+cn) IN 0 ALIAS sn
SELECT sn
SET RELATION TO jnh INTO "ss"
REPLACE ALL ;
("ss.M"+cn+"_1") WITH EVALUATE("sn.M"+cn+"_1"),;
("ss.M"+cn+"_2") WITH EVALUATE("sn.M"+cn+"_2"),;
("ss.M"+cn+"_3") WITH EVALUATE("sn.M"+cn+"_3")
SET RELATION TO
USE IN "sn"
ENDFUNC