On Sun, 20 Jun 2021 16:09:54 +0100, Jeremy Nicoll wrote: > >> So what would you do? Suppose it'd not just three things >> that need to be exclued first but, say, twenty? > >select > when words(f!ce_bfe) \== 1 then f!ce_err = "bfe '"f!ce_bfe"' not a single > word" > when \datatype(f!ce_ssn,"W") then f!ce_err = "ssn '"f!ce_ssn"' not a whole > number" > when \datatype(f!ce_ssx,"W") then f!ce_err = "ssx '"f!ce_ssx"' not a whole > number" > when \datatype(f!ce_wcn,"W") then f!ce_err = "wcn '"f!ce_wcn"' not a whole > number" > when \datatype(f!ce_wcx,"W") then f!ce_err = "wcx '"f!ce_wcx"' not a whole > number" > when \datatype(f!ce_wln,"W") then f!ce_err = "wln '"f!ce_wln"' not a whole > number" > when \datatype(f!ce_wlx,"W") then f!ce_err = "wlx '"f!ce_wlx"' not a whole > number" > when \datatype(f!ce_wld,"W") then f!ce_err = "wld '"f!ce_wld"' not a whole > number" > otherwise f!ce_err = "" >end > I see. I'd be inclined to code the repetitive part of that as a loop.
>if f!ce_err \== "" then do > f!ce_rettxt = f!ce_errpfx f!ce_err > signal func_jn_chk_encp_z >end > SIGNAL? I suppose it's OK here. But I came to loathe the style of a co-worker who coded his major loops with SIGNAL, never DO, because once he used a SIGNAL, DO was unusable. You can write FORTRAN in any language. -- gil ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN
