Table structure?

Ruslan Zasukhin sunshine at public.kherson.ua
Fri Apr 28 23:01:13 CDT 2006


On 4/28/06 8:10 PM, "Joakim Schramm" <joakim at astrocalc.com> wrote:

> The lookup data is really sort of a DateTime value in 16 character string
> where each DT has a result value in a second field, were DT mark a boundury
> to set a value. I was thinking of using IVDateTime but the examples in the
> docs (at least VCOM) are really sparse so not sure if this would do? Instead
> of just a single line or two shoing how to asign and read a value, it would
> be really bice (and helpful) if the was at least a small piece of code
> showing a typical context to use it together with other calls. It exists in
> a few places, but far to few. I know, you are probably aware of it, but
> ponting it out anyway. The documentation is also a bit contradictional on
> this, while the VCOM doc show you can set date format, kernel doc say it's
> depends on system settings (internal storage), what matter to me of course
> is what I get when need to use this value in my other code?
> 
> Just to give as an example, my data looks something like this with | as
> field separator
> 
> 19971026030000|-1
> 19980329020000|-2
> 19981025030000|-1
> 19990328020000|-2
> 19991031030000|-1
> 20000326020000|-2
> 20001029030000|-1
> 
> Lets say if I make a lookup using the value 19990429073000 (29 April 1999
> 07:30:00) it will return me -2 as it's more then 19990328020000 but not as
> much as 19991031030000, but it's really not the comparison I am after here
> but the best way to structure the data.

Of course you can store this DateTime values into VCOM IVDateTime type.

You even will win in db size and therefore in speed.

Now you spend 16 + 1 bytes per value.
With DateTime field of Valentina you will use 8 bytes.
    so you win about 4MB in table,
    and about 6 MB in the index file if it exists


-- 
Best regards,

Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc

Valentina - Joining Worlds of Information
http://www.paradigmasoft.com

[I feel the need: the need for speed]




More information about the Valentina mailing list