Skip to Content.
Sympa Menu

freetds - Re: timestamps - a Stamping Problem? (Bus Error)

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Karl Pielorz <kpielorz AT tdx.co.uk>
  • To: TDS Development Group <freetds AT franklin.oit.unc.edu>
  • Subject: Re: timestamps - a Stamping Problem? (Bus Error)
  • Date: Wed, 26 Apr 2000 11:39:12 +0100




Maraya Michael wrote:
>
> The name TIMESTAMP is deceptive. It's intended to generate a unique
> value and is not meant for retrieving the actual time.


A hopefully 'useful' workaround to others...

replacing:

SELECT user_id, status, timestamp FROM config;

with:

SELECT user_id, status, CAST( timestamp AS int ) AS timestamp FROM config;

Means FreeTDS doesn't die, I get the timestamp, and all it happy... On the
MySQL side I've just used an INT to hold this... If the INT is 4 bytes, and
the TIMESTAMP on MS-SQL is 8 Bytes, I realise theres a potential overflow, but
not 'till the tables had 4bn insert/updates :-)

-Karl




Archive powered by MHonArc 2.6.24.

Top of Page