Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Check in between dates
Message
From
08/10/2003 03:21:28
 
 
To
08/10/2003 01:46:11
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00836067
Message ID:
00836077
Views:
14
This message has been marked as the solution to the initial question of the thread.
>i have in my table fields frdate and todate.
>
>in my form i have inputs for from and to date, that i want to check if this is already in my table.
>
>say in my table i already have frdate={10/01/2003} and todate={10/12/2003}. if my user inputs from and to date, {10/02/2003} and {10/02/2003} i want to prompt a message that it is already in the table.
>
>i know how to check if a date is in between, between(mydate,frdate,todate). but how to check from and to date if it's in the table already?
>
>pls help.

Evelyn,

Do you want to check for overlapping dates ?
In that case
locate for between(InputDateFrom, Table.FrDate, Table.ToDate) or  between(InputDateTo, Table.FrDate, Table.ToDate)
Overlap = Found()
Gregory
Previous
Reply
Map
View

Click here to load this message in the networking platform