Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Date calculation problem
Message
From
27/12/2001 13:43:30
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00598520
Message ID:
00598523
Views:
22
>I am having problem with the following formula
>ROUND(((DATE()-(DATE()-Payroll_tbl.edate))-Employee.e_cntysnrdte)/365.25,1)
>
>
>where my Payroll_tbl.edate = 11/30/01 and my Employee.e_cntysnrdte = 03/11/00
>I get the result of 101.7 instead of 1.7
>
>
>
>Thanks
>Nick Patel

Nick,
That formula essentially same as :

ROUND((Payroll_tbl.edate-Employee.e_cntysnrdte)/365.25,1)

And I think problem comes from the fact that e_cntysnrdte value 03/11/00 is 03/11/1900.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Reply
Map
View

Click here to load this message in the networking platform