EXECUTE BLOCK AS
DECLARE VARIABLE stmt VARCHAR(1000);
BEGIN
FOR SELECT 'SET GENERATOR ' || RDB$GENERATOR_NAME || ' TO 0;'
FROM RDB$GENERATORS
WHERE (RDB$SYSTEM_FLAG IS NULL) OR (RDB$SYSTEM_FLAG <> 1)
AND NOT RDB$GENERATOR_NAME STARTING 'IBE$'
ORDER BY RDB$GENERATOR_NAME
INTO :STMT
DO EXECUTE STATEMENT :STMT; END