Re: Detecting broken connection to Sybase server.
- From: seamonster76@xxxxxxxxx
- Date: 16 Aug 2005 12:27:36 -0700
Thanks for you suggestion. I made some change to my code to something
similar to the following. However, the ct_con_props still reset status
to 0. Did I get you right?
Thanks
Andy
if ( CS_FAIL == (nRetVal = ct_send(m_pCmd) ) )
{
ct_cancel(NULL, m_pCmd, CS_CANCEL_ALL) ;
CS_INT status = CS_CONSTAT_DEAD;
ct_con_props(m_pDatabase->pCnx, CS_GET, CS_CON_STATUS,
NULL, 0, &status);
if(status & CS_CONSTAT_DEAD)
{
// connection failed!
}
}
// make sure that send worked OK
if (CS_FAIL == (nRetVal = ct_results( m_pCmd, &nRetVal2) ) )
{
ct_cancel(NULL, m_pCmd, CS_CANCEL_ALL) ;
CS_INT status = CS_CONSTAT_DEAD;
ct_con_props(m_pDatabase->pCnx, CS_GET, CS_CON_STATUS,
NULL, 0, &status);
if(status & CS_CONSTAT_DEAD)
{
// connection failed!
}
}
.
- Follow-Ups:
- Re: Detecting broken connection to Sybase server.
- From: seamonster76
- Re: Detecting broken connection to Sybase server.
- References:
- Detecting broken connection to Sybase server.
- From: seamonster76
- Re: Detecting broken connection to Sybase server.
- From: SybaseNeal
- Re: Detecting broken connection to Sybase server.
- From: seamonster76
- Re: Detecting broken connection to Sybase server.
- From: SybaseNeal
- Detecting broken connection to Sybase server.
- Prev by Date: Procedure erors and dbo versus dbo-alias for compiling
- Next by Date: Re: Procedure erors and dbo versus dbo-alias for compiling
- Previous by thread: Re: Detecting broken connection to Sybase server.
- Next by thread: Re: Detecting broken connection to Sybase server.
- Index(es):
Relevant Pages
|
|