Your syntax for the DO CASE command is incorrect. It should be of the following form:
DO CASE
CASE CDOW(DATE()) = 'Monday'
...etc...
You don't want the equal sign ("=") after CASE.
Try this and see how it goes.
Larry Huisingh
>I have the following code. I am trying to delete records in a table. Depending on the day of week, the program needs to delete a certain calculation of the date on the PC.
>
>USE ach_clears IN 0 ORDER clear_date EXCLUSIVE
> SELECT ach_clears
>
> DO CASE
>
> CASE = CDOW(DATE()) = 'Monday'
>
> DELETE ALL FOR clear_date > DATE() - 4
>
..<snip>..
>It seems that none of these conditions are true and nothing gets deleted. Am I thinking wrong?
Larry Huisingh
Lockheed Martin Information Technology
Richland WA USA