Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

Managing ODBC Connections

2 posts in General Discussion Last posting was on 2009-06-26 18:00:04.0Z
Jim B Posted on 2009-06-11 16:23:30.0Z
Sender: 3fba.4a2d127d.1804289383@sybase.com
From: Jim B
Newsgroups: sybase.public.impact
Subject: Managing ODBC Connections
X-Mailer: WebNews to Mail Gateway v1.1t
Message-ID: <4a312f82.6c40.1681692777@sybase.com>
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 11 Jun 2009 09:23:30 -0700
X-Trace: forums-1-dub 1244737410 10.22.241.41 (11 Jun 2009 09:23:30 -0700)
X-Original-Trace: 11 Jun 2009 09:23:30 -0700, 10.22.241.41
Lines: 20
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.impact:2190
Article PK: 230264

To all developers using an ODBC connection to access a
database from Impact. I'm interested in your methods to
manage the ODBC connection from within a prod object in an
SFM. How do you detect the loss of a ODBC connection to
prevent a messages from canceling?

I've given up on using the Built-in DB function and now
attempting to use the exec() function in a custom filter.
Works great but if the ODBC connection is lost (ex. database
restart), the exec stmt will fail and the message is
canceled. The rv can be inspected from the exec stmt and a
connectStr() function issued to re-connect but the message
cancels immediately when exec() fails. I'm trying to
prevent the canceling of the message.

Looking for a method to determine the health of the ODBC
connection prior to issuing an exec()function so that a new
connection can be made if necessary.

Anyone aware of ODBC options that would auto reconnect?


Larry Tafelski Posted on 2009-06-26 18:00:04.0Z
Sender: 3088.4a450bca.1804289383@sybase.com
From: Larry Tafelski
Newsgroups: sybase.public.impact
Subject: Re: Managing ODBC Connections
X-Mailer: WebNews to Mail Gateway v1.1t
Message-ID: <4a450ca4.3142.1681692777@sybase.com>
References: <4a312f82.6c40.1681692777@sybase.com>
NNTP-Posting-Host: forums-3-dub.sybase.com
X-Original-NNTP-Posting-Host: forums-3-dub.sybase.com
Date: 26 Jun 2009 11:00:04 -0700
X-Trace: forums-3-dub.sybase.com 1246039204 10.22.241.188 (26 Jun 2009 11:00:04 -0700)
X-Original-Trace: 26 Jun 2009 11:00:04 -0700, forums-3-dub.sybase.com
Lines: 30
Path: forums-1-dub!forums-master!forums-3-dub.sybase.com!not-for-mail
Xref: forums-1-dub sybase.public.impact:2194
Article PK: 230269

Hi, I am looking into creating a production object
interface to a SQL database and was thinking of using the
built in DB function. What problems are you seeing? What
platform are you running on?

Thanks,

Larry Tafelski

> To all developers using an ODBC connection to access a
> database from Impact. I'm interested in your methods to
> manage the ODBC connection from within a prod object in an
> SFM. How do you detect the loss of a ODBC connection to
> prevent a messages from canceling?
>
> I've given up on using the Built-in DB function and now
> attempting to use the exec() function in a custom filter.
> Works great but if the ODBC connection is lost (ex.
> database restart), the exec stmt will fail and the message
> is canceled. The rv can be inspected from the exec stmt
> and a connectStr() function issued to re-connect but the
> message cancels immediately when exec() fails. I'm trying
> to prevent the canceling of the message.
>
> Looking for a method to determine the health of the ODBC
> connection prior to issuing an exec()function so that a
> new connection can be made if necessary.
>
> Anyone aware of ODBC options that would auto reconnect?