>Hi everybody,
>
>We have a DTOS function, but what we should use for datetime fields? My colleague was using ttoc and the search expression didn't work. I suggested to use DTOS(TTOD(datetimefield)) and it solved the problem. However, I'm wondering what is the correct approach here?
>
>Thanks in advance.
It all depends of what is the INDEX Expression, If table is indexed by DTOS(DateTimeField) you must use DTOS(). There is no need to use DTOS(TTOC()), because DTOS() works with DateTime type as well as with Date type.
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.