[egenix-users] "right truncation" warning in mx.ODBC.Windows

Jim Vickroy Jim.Vickroy at noaa.gov
Tue Mar 16 12:18:27 CET 2004


I too, thought I reported this problem some time in the **distant** past,
but maybe I am mistaken <smile>.

Anyway, MS SQL Server has a time resolution of 3.33 milliseconds; see for
example:

http://www.databasejournal.com/features/mssql/article.php/1442361#part_4

My experience has been that trying to press that limit still triggers
occassional warnings; truncating mx.DateTime objects to centi-seconds for
insertion in MS SQL Server definitely works with the two versions (6, 7) I
have encountered.

-- jv


-----Original Message-----
From: egenix-users-bounces at lists.egenix.com
[mailto:egenix-users-bounces at lists.egenix.com]On Behalf Of M.-A. Lemburg
Sent: Monday, March 15, 2004 7:41 AM
To: sholden at holdenweb.com
Cc: Egenix-Users at Lists.Egenix.Com
Subject: Re: [egenix-users] "right truncation" warning in
mx.ODBC.Windows


Steve Holden wrote:
> I just ran a test. Despite the fact that Microsoft suggest otherwise,
> most "hundredth-second" intervals fail - I ran a test, adding i/100 to
> an integral ticks value for i in range(99).
>
> The only ones that worked were the quarter-seconds (0.25, 0.5, 0.75).
> So, rounding to the nearest 250 mS should work, for some value of
> "work".

Thanks for checking. Unless we find a better alternative, I
guess rounding to the nearest quarter of a second is the
way to go... or maybe we can just silence the warning in this
particular case.

Thanks,
--
Marc-Andre Lemburg
eGenix.com

Professional Python Services directly from the Source  (#1, Mar 15 2004)
 >>> Python/Zope Consulting and Support ...        http://www.egenix.com/
 >>> mxODBC.Zope.Database.Adapter ...             http://zope.egenix.com/
 >>> mxODBC, mxDateTime, mxTextTools ...        http://python.egenix.com/
________________________________________________________________________
Python UK 2004, Oxford, UK                                  31 days left
EuroPython 2004, Göteborg, Sweden                           83 days left

::: Try mxODBC.Zope.DA for Windows,Linux,Solaris,FreeBSD for free ! ::::


_______________________________________________________________________
eGenix.com User Mailing List                     http://www.egenix.com/
http://lists.egenix.com/mailman/listinfo/egenix-users



More information about the egenix-users mailing list