> I need to increase the UDF_TIMEOUT value within the scope of a job, and
> had hoped to use CHGQRYA to do this. However there seems to be no
[quoted text clipped - 4 lines]
>
> Is there any way to set UDF_TIMEOUT within a job's scope?
Hello.
Create a copy of QAQQINI in some library, change this parameter there
and call CHGQRYA command with this file before you use your udf.
You can call CL commands from SP/UDF with this procedure:
-----
CREATE PROCEDURE DWH.QCMDEXC2(IN CMD VARCHAR(4096))
LANGUAGE SQL
BEGIN
DECLARE CMDLEN DECIMAL(15,5);
SET CMD=TRIM(CMD);
SET CMDLEN = LENGTH(CMD);
CALL QSYS.QCMDEXC(CMD, CMDLEN);
END;
-----
and in your SP/UDF:
-----
DECLARE stmt VARCHAR(4096);
DECLARE cmdlen DECIMAL(15, 5);
--DWH there is my library name
SET stmt = 'CHGQRYA QRYOPTLIB(DWH)';
SET cmdlen = LENGTH(stmt);
call qsys.qcmdexc(stmt, cmdlen);
-----
I do so and it works.
Sincerely,
Mark B.
JohnO - 07 Jun 2006 20:55 GMT
> > I need to increase the UDF_TIMEOUT value within the scope of a job, and
> > had hoped to use CHGQRYA to do this. However there seems to be no
[quoted text clipped - 32 lines]
> Sincerely,
> Mark B.
Hey, good thinking!
Thanks,
JohnO
JohnO - 07 Jun 2006 20:57 GMT
> > I need to increase the UDF_TIMEOUT value within the scope of a job, and
> > had hoped to use CHGQRYA to do this. However there seems to be no
[quoted text clipped - 32 lines]
> Sincerely,
> Mark B.
Hey Mark, just wondering... if my QAQQINI copy has just one entry,
UDF_TIMEOUT, rather than being a full copy of the usual QAQQINI, would
the system be smart enough to inherit the original settings for all the
values? Or is that just wishful thinking?
Cheers,
JohnO
Kent Milligan - 09 Jun 2006 16:14 GMT
Yes, DB2 for i5/OS is smart enough to do that.
Depending on the interface that you're using, you can also specify your
"private" QAQQINI file with a connection property and have the driver execute
the CHGQRYA for you.
>>> I need to increase the UDF_TIMEOUT value within the scope of a job, and
>>> had hoped to use CHGQRYA to do this. However there seems to be no
[quoted text clipped - 39 lines]
> Cheers,
> JohnO

Signature
Kent Milligan
ISV Enablement - System i
kmill@us.eye-bee-m.com (spam trick) GO HAWKEYES!!
>>> ibm.com/iseires/db2
(opinions stated are not necessarily those of my employer)