Maintain DB2 Connection On Subsequent Page Loads

General discussion on PHP
Post Reply
jord1322
Posts: 36
Joined: Mon Nov 03, 2014 3:49 pm
Location: Concord, North Carolina

Maintain DB2 Connection On Subsequent Page Loads

Post by jord1322 » Tue Aug 02, 2016 3:59 pm

Hello,

I'm not sure that this is possible, but I'm going to ask anyway. Haha

Is there a way to maintain the same connection to the database as opened in the current application for use in subsequent application/page loads? I know with persistent connections I can leave the connection open and I may get the same connection, but that it is not certain. That will not work. Specifically I need to be able to use the previously established connection to the database for my Toolkit so that I can use the QTEMP library to read and maintain information. However, at present, since PHP/HTML is stateless I cannot pass the connection as either a GET or SESSION variable to be able to maintain it for future use. If you know of a way, especially one that would allow the use of the same connection over AJAX (or without AJAX), please let me know. Thanks!
Thanks,
Jordon Greene
PHP Full Stack Developer
SHOE SHOW, Inc.

scottgcampbell
Posts: 187
Joined: Wed Apr 22, 2009 2:29 pm
Location: Edmonton, AB, Canada

Re: Maintain DB2 Connection On Subsequent Page Loads

Post by scottgcampbell » Thu Aug 04, 2016 1:51 pm

Jordon,

I think this will give you your answer (or at least hopefully point you in the correct direction). It discusses the different XMLSERVICE Connection options, I've never used anything but stateless.
http://yips.idevcloud.com/wiki/index.ph ... ICEConnect

What type of information are you looking to store in QTEMP? Would you be able to save the info in the session instead (or is it too large)?

Scott

jord1322
Posts: 36
Joined: Mon Nov 03, 2014 3:49 pm
Location: Concord, North Carolina

Re: Maintain DB2 Connection On Subsequent Page Loads

Post by jord1322 » Thu Aug 04, 2016 1:56 pm

scottgcampbell wrote:Jordon,

I think this will give you your answer (or at least hopefully point you in the correct direction). It discusses the different XMLSERVICE Connection options, I've never used anything but stateless.
http://yips.idevcloud.com/wiki/index.ph ... ICEConnect

What type of information are you looking to store in QTEMP? Would you be able to save the info in the session instead (or is it too large)?

Scott

It's much too large unfortunately.
Thanks,
Jordon Greene
PHP Full Stack Developer
SHOE SHOW, Inc.

Post Reply