Page 1 of 1

Establish DB2 Connection in runtime

Posted: Tue Mar 27, 2012 12:06 am
by patelamit009
Hi All,

My job design is as follows.

DB2 Connector (fetch from DB2 table) ----> Aggregator ----> DB2 Connector ( to load Mainframe table).

The problem i am facing here is the below error
SQLExecute reported: SQLSTATE = 08506: Native Error Code = -30,108: Msg = [IBM][CLI Driver][DB2] SQL30108N A connection failed but has been re-established.

The reason being, the idle timeout. For eg, here im fetching 2 million records which takes around 2 minutes. And the idle timeout in the traget DB2 connection is 1 minute. Hence when the data propagetes to target the connection is getting lost.

So, i would like to know if we could establish db2 connection in the target after the whole data is fetched from the source ?

Thanks.

PS : Admins, please correct me if my post is not as per the standards set.

Posted: Tue Mar 27, 2012 7:30 am
by chulett
A 1 minute idle timeout? Sheesh. No, there's no ability to defer the target connection until the source data is ready in any sense.

Look for some kind of a 'keep alive' parameter in the connector, pretty sure I've seen people here mention the fact that at least some of them have this capability.

Posted: Tue Mar 27, 2012 2:54 pm
by ray.wurlod
You could do it with two jobs - extract into staging area (e.g. Data Set) then load from that in a separate job.

Re: Establish DB2 Connection in runtime

Posted: Tue Mar 27, 2012 4:28 pm
by qt_ky
patelamit009 wrote:So, i would like to know if we could establish db2 connection in the target after the whole data is fetched from the source ?
The easy solution is:

Job 1:

DB2 Connector (fetch from DB2 table) ----> Aggregator ----> Data Set stage.

Job 2:

Data Set stage ----> DB2 Connector ( to load Mainframe table).

Posted: Tue Mar 27, 2012 4:34 pm
by qt_ky
I just saw Ray's reply... Same idea, fewer words!

Posted: Tue Mar 27, 2012 4:36 pm
by qt_ky
The DB2 Connector stage does have a keep alive setting for the conductor node (default=Yes), but I don't think it works in the way you probably think of a keep-alive normally working like on a telnet or VPN session. The setting is there in 8.5 and 8.7. I think on 8.1 it requires a patch to get that setting.

Posted: Tue Mar 27, 2012 8:03 pm
by patelamit009
Thanks All.

I shall try your valuable inputs as
1. Getting patch for 8.1
2. Using staging datasets.

Any further updates are welcome.