Filter for Top X

Apr 1, 2016 at 5:40 PM

I have an entity type with devices, and another holding device history. Everything works well, but I'd like a way to select the most recent history entry. I have found an easy enough way to do it in the razor script, but it would be cool to do directly in the query.

So, is there a filter/method for selecting the "top x" or something of records, such that I could do "give me the first result" after a sort?


Apr 4, 2016 at 9:39 AM
You could use the paging query-part, to deliver the top 1