Either I am totally standing on the line or this is weird.
having
a = {^2002-05-10 16:18:00}
b = {^2002-05-10 16:19:00}
This should make a minute if I separate them from each other and
devide by 60 right?
? b - 1 and
? (b-a) / 60
should be 60 or 1 respectively. And if I do this, my screen shows me 1.0000. So far, so good.
However putting this into a table with an integer endurance-field leaves
0 there
so I tried
? int((b-a) / 60 )
and this gave me 0
Maybe this was to complicated for my system. So make it in two
steps
x = b - a
? x ==> 60
? int(x / 60) ==> 0
After this did not make too much sense, I set decimals to 15. And see:
? (b-a) / 60
actually is
0.99999994039535500
Just as every little child knows 60 / 60 is 0.99999994039535500.
So the trick to make this work actually is to employ round()
int( round(b-a, 1) / 60 )
actually works.
But I thought this might be interesting for the one or the other as it was not truely obvious (to me). If you like, tell me if You can reproduce this.
It's VFP7 SP1, German edition, WinNT 4.0 SP6a
set DATE GERMAN
set POINT to ","
set SEPARATOR to "."
P.S. I have the same behaviour in VFP 6 SP5