Issue with TIME fields.
Russ Tyndall
fitzbew at nc.rr.com
Wed Sep 13 09:29:46 CDT 2006
On 9/13/06 3:36 AM, "Ruslan Zasukhin" <sunshine at public.kherson.ua> wrote:
> Hi Guys,
>
> * You three was able produce this issue.
>
> * you all it seems have create db on MAC.
>
> * after this
> Russ have see issue in V4RB MACHO client
> Ray it seems in ADK?
> Chris on Windows in the moved from mac db.
>
> * In 2 cases we have get your dbs and was able see next:
>
> - we pack TIME value into ULONG 4 bytes = 32 bits
>
> - but some last bits are not used.
>
> - we see that in database these bits are not ZEROED.
>
> This results that GetString() produce correct value.
> We see it correct in viSQL, app or Vstudio.
>
I seem to recall that the displayed values of the field in Vstudio were
subsequently incorrect in my testing. (after I copied database out of
Vserver databases folder and opened in Vstudio in local mode.)
> But if this value from DB is compared as LONG == LONG to other values
> produced for search of course COMPARE fails.
>
>
> -------
> I have check all sources and places where we assign time values,
> I do not see how this bits can catch garbage.
>
> So my question to you is: WHAT WAY you have to use to assign time or
> datetime value into database?
>
> A) SQL:
>
> INSERT ..... VALUES ( '12:12:12' )
>
> B) SQL + Cursor:
>
> curs.TimeField(1).value = '12:12:12'
>
> Or
>
> curs.TimeField(1).SetString('12:12:12')
>
>
> C) VTable API ?
>
In my testing, it was not interaction with the DateTimefield *alone* that
munged the date value; to duplicate the bug in Mach-o in a small project I
had to *also* update a Stringfield in the same cursor. If I did not update
that stringfield in cursor, everything worked fine.
The test project I sent you for 1738 displays this problem very vividly;
however, I realize debugging mach-o is hard inside your sources.
In my project, I can (even in Macho client) update DateTimefield ok, as long
as I do not update Stringfield in same cursor.
I do not see this bug in local mode at all, in any type of build. Only as
client of Vserver.
I hope this helps.
--
Russ Tyndall
Wake Forest, NC
More information about the Valentina
mailing list