Hi @Meneghino
Thanks for you answer. I made a lot of tests, but to no avail. Here are my observations:
SortByColumns(Filter('[dbo].[logbog]',Date(2017, 4, 1) > dato), "dato",If(SortDescending1, Ascending,Descending))
Error: We cannot apply operator < to types Date and DateTimeZone
(note – my operator is >, not <, as in the message
SortByColumns(Filter('[dbo].[logbog]',Date(2017,4,2)+Time(11, 10, 0, 0) >= dato), "dato",If(SortDescending1, Ascending,Descending))
The same error: We cannot apply operator < to types Date and DateTimeZone
But there is no error, if I use = (equal) operator instead >
No error even with
SortByColumns(Filter('[dbo].[logbog]',DatePicker1.SelectedDate= dato), "dato",If(SortDescending1, Ascending,Descending))
But no data is displayed.
I want (very simple thing) - to show my records from data table only for a particular day. My data table has a dato column, which is DateTime type, i.e. contains date and time. I believe that the right filter condition should be
Filter('[dbo].[logbog]',DateOnly(dato) = DatePicker1.SelectedDate)
But I do not know which is the function to truncate time from DateTime (DateOnly(dato)), so I decided to convert both to text and compare that in the filter like this:
SortByColumns(Filter('[dbo].[logbog]',Text(DatePicker1.SelectedDate,ShortDate) = Text(dato,ShortDate)), "dato",If(SortDescending1, Ascending,Descending))
Now - no error, only warning: "Part of this filter formula cannot be evaluated remotely due to service limitation..."
But the result is again empty
How can I return and display only data for a one particular day from my data table?
I am very confused not able to perform such a simple task...
Thanks,
Yakimo