[freetds] freeTDS 6.1 & OpenClient

Shahryar G. Hashemi shahryar at n2h2.com
Fri May 2 17:13:41 EDT 2003


This particular server is 3rd party and they seemed to have coded it to not 
use @@ variables.  I believe with the OpenClient/C code you can setup your own 
proprietary server to do anything you want [or not want to do].

What might be a good test if a config variable that says "ignore_dbspid" and 
would skip the check if the given server you connect to does not handle it 
properly.

Shahryar

On Fri, 2 May 2003, Lowden, James K wrote:

> Date: Fri, 2 May 2003 17:00:12 -0400 
> From: "Lowden, James K" <LowdenJK at bernstein.com>
> To: "'shahryar at n2h2.com'" <shahryar at n2h2.com>,
>      'FreeTDS Development Group' <freetds at lists.ibiblio.org>
> Subject: RE: [freetds] freeTDS 6.1 & OpenClient
> 
> > From: Shahryar G. Hashemi [mailto:shahryar at n2h2.com]
> > Sent: May 2, 2003 3:49 PM
> > 
> > The question then is why is this check being performed.  Is 
> > this for an MS SQL 
> > test?
> 
> We support:
> 	
> 	int dbspid(DBPROCESS * dbproc);
> 
> in db-lib.  
> 
> Until today, I'd never heard of a server without @@ variables, so, until
> today, if that test failed, it was a problem with FreeTDS or the connection.
> 
> 
> Is there another way to get the process id?  Sybase doesn't define a failure
> condition for dbspid().  
> 
> --jkl
> 
> 
> > 
> > Shahryar
> > 
> > On 2 May 2003, Frediano Ziglio wrote:
> > 
> > > Date: 02 May 2003 20:51:54 +0200
> > > From: Frediano Ziglio <freddyz77 at tin.it>
> > > To: shahryar at n2h2.com, FreeTDS Development Group 
> > <freetds at lists.ibiblio.org>
> > > Subject: Re: [freetds] freeTDS 6.1 & OpenClient
> > > 
> > > 
> > > > The server in question does not have any @@ variables [it 
> > was built off of 
> > > > OpenClient/C and they never included hangling of @@ 
> > variables].  How do I turn 
> > > > this off so that this check doesn't happen?  I have used 
> > TDS version 4.2 -> 
> > > > 5.0.
> > > > 
> > > > Any help would be greatly appreciated.
> > > > 
> > > 
> > > In token.c remove these lines
> > > 
> > > 	tds->spid = tds->rows_affected;
> > > 	if (tds->spid == 0) {
> > > 		if (tds_set_spid(tds) != TDS_SUCCEED) {
> > > 			tdsdump_log(TDS_DBG_ERROR, "%L 
> > tds_set_spid() failed\n");
> > > 			succeed = TDS_FAIL;
> > > 		}
> > > 	}
> > > 
> > > This should fix your problem... There is a function of 
> > DB-Library that
> > > return pid, this won't work but I don't think it's a big problem ...
> > > 
> > > freddy77
> > > 
> > > 
> > 
> > -- 
> > Shahryar Ghazneini Hashemi        | Cell Phone:      +1 206 604-7852
> > DBA - Operations Group            | Telephone:       +1 206 834-1739
> > N2H2 Inc.                         | Pager:           +1 206 609-6154
> > 900 4th Avenue  Suite #3600       | FAX:             +1 206 336-2971
> > Seattle, WA  98164    U.S.A.      | E-MAIL:          
> > shahryar at n2h2.com 
> > ==============================================================
> > ================
> > 
> > _______________________________________________
> > FreeTDS mailing list
> > FreeTDS at lists.ibiblio.org
> > http://lists.ibiblio.org/mailman/listinfo/freetds
> > 
> 
> 
> The information contained in this transmission may contain privileged and
> confidential information and is intended only for the use of the person(s)
> named above.  If you are not the intended recipient, or an employee or agent
> responsible for delivering this message to the intended recipient, any
> review, dissemination, distribution or duplication of this communication is
> strictly prohibited. If you are not the intended recipient, please contact
> the sender immediately by reply e-mail and destroy all copies of the
> original message. Please note that we do not accept account orders and/or
> instructions by e-mail, and therefore will not be responsible for carrying
> out such orders and/or instructions.
> 
> 

-- 
Shahryar Ghazneini Hashemi        | Cell Phone:      +1 206 604-7852
DBA - Operations Group            | Telephone:       +1 206 834-1739
N2H2 Inc.                         | Pager:           +1 206 609-6154
900 4th Avenue  Suite #3600       | FAX:             +1 206 336-2971
Seattle, WA  98164    U.S.A.      | E-MAIL:          shahryar at n2h2.com 
==============================================================================




More information about the FreeTDS mailing list