select (name) case(a=b): if (d=e) { ----->keep this opening brace in call pgmA; if loop return rc; } ----->keep this closing brace default: call pgmB; END; ----->change last } to END;