Read the help topic on Date():
What you call message is your default value expression. With "message", Mike meant the error message you get displayed when trying to set that default value expression, but it helps to see the full expression, too, as the screenshot cuts that off and the selected line is unreadable for me on my large display, much too small. So thanks for that essential info, it always helps to provide code as text and not screenshot.
You simply make the wrong usage of the date() function, I initially linked to the definition you'd need to use.
A date literal - a date value needing no function like DATE() to be created - also is possible, that would have the format {^YYYY-MM-DD} in VFP, so perhaps the shortest possible way to do that is:
[tt]iif(date_sal={^2017-07-01},1000,0)[/tt]
Your initial post indicates you want this for two dates, also for 01/01/2017, that could be done with an ICASE, which would also allow assigning different default values per date:
[tt]icase(date_sal={^2017-07-01},1000,date_sal={^2017-01-01},1000,0)[/tt]
or for the same default you may use
[tt]iif(date_sal={^2017-07-01} OR date_sal={^2017-07-01},1000,0)[/tt]
But surely you will
not use
[tt]iif(date_sal={^2017-07-01} AND date_sal={^2017-07-01},1000,0)[/tt]
or
[tt]iif(date_sal={^2017-07-01} AND {^2017-07-01},1000,0)[/tt]
If you have any legacy VFP background, what you had in mind when you wrote date(01/07/2017) might have been CTOD('01/07/2017'), but I would not recommend that, as it depends on settings, different countries have different formats for dates, not only in the order of day and month. {^YYYY-MM-DD} is a universal way to write a date independent of such regional differences.
Bye, Olaf.