Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
In this Gist, we see how we can query the Db2 for i Health Center and inquire what Environmental Limits shows as the jobs that consumed the most activation groups within a single job, where the activation group executed SQL.
--
-- description: Since the last IPL, which jobs have used the most Activation Groups to execute SQL?
-- resource: https://www.ibm.com/support/knowledgecenter/en/ssw_ibm_i_74/rzajq/rzajqhealthenvlimits.htm
-- minvrm: V6R1M0
--
select b.sizing_name,
a.highwater_mark,
a.when_recorded,
a.job_name,
a.current_user,
a.job_type,
a.job_status,
a.client_wrkstnname,
a.client_applname,
a.client_acctng,
a.client_programid,
a.client_userid,
a.limits_established,
a.interface_name,
a.interface_type,
a.interface_level
from table (
qsys2.environmental_limits()
) as a,
qsys2.sql_sizing as b
where a.limit_id = b.sizing_id and sizing_id = 18202;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment