Skip to Content.
Sympa Menu

freetds - Re: Example source codes

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "Carlos E. G. Carvalho" <cartola AT techmaster.com.br>
  • To: TDS Development Group <freetds AT franklin.oit.unc.edu>
  • Subject: Re: Example source codes
  • Date: Mon, 30 Aug 1999 18:50:48 -0300 (EST)


Hmm, looks very nice. What about datetime and timestamp? Am I able
to access them as strings? I guess I have tried this in one test and as a
result I didn't get the columns after the datetime one...

Thanks again,

[]s,

Carlos E. G. Carvalho

On Mon, 30 Aug 1999, Brian Bruns wrote:

>
> Text and image types are likely to be a problem in dblib, the TDS layer
> works ok, but dblib has no support for them. I'll see if I can look
> into it this week. (Anyone have some dblib sample code using text/image to
> play with?)
>
> Floats are fairly simple. Here is a code fragment to demonstrate it. Note:
> there were some problems with earlier versions, it's probably best to grab
> a recent snapshot of freetds.
>
> DBFLT8 flt;
>
> /* init stuff */
>
> dbcmd(dbproc,"select size from floater");
> dbsqlexec(dbproc);
> while (dbresults(dbproc)!=NO_MORE_RESULTS) {
> dbbind(dbproc,1,FLT8BIND,-1,(BYTE *) &flt);
> while (dbnextrow(dbproc)!=NO_MORE_ROWS)
> printf("%6.3g\n",flt);
> }
>
> /* clean up */
>
>
> Reals work similarly but using the var type DBREAL and bind type REALBIND
> instead of DBFLT8 and FLT8BIND respectively.
>
> On Mon, 30 Aug 1999, Carlos E. G. Carvalho wrote:
>
> > Hi, I am using dblib from freetds recently in a freebsd accessing
> > a database in a MS SQL Server 6.5. I am having some dificulties in
> > retriving some data types. Does anybody have some source code that uses
> > dblib accessing data types like floats, image, text, etc, I mean, other
> > than int and char (those that come with the tests in the unittest in
> > dblib).
> >
> > Thanks, cheers,
> >
> > Carlos E. G. Carvalho
> >
> >
> >
> > ---
> > You are currently subscribed to freetds as: camber AT ais.org
> > To unsubscribe, forward this message to $subst('Email.Unsub')
> >
> >
>
>
> ---
> You are currently subscribed to freetds as: cartola AT techmaster.com.br
> To unsubscribe, forward this message to $subst('Email.Unsub')
>





Archive powered by MHonArc 2.6.24.

Top of Page