1

We have developed a logistic domain system that deals with millions of records. In order to show the records as per the filter applied by the user, we were fetching the data with filtering conditions included in the query and fetching back the result.

Now we have implemented ODataController to our system, After implementation the performance has reduced and its taking much time to execute the user actions.

I have an ODataController. Inside that I have a GetAllDetails() method that returns IQueryable result.

I have 3 million details in my database. I need to show 100 records per page on the table.

Is the ODataController executes the query first and then applies filter on it? How can I improve the performance?

[EnableQuery]

public IQueryable<ScanDetail> Get()
{
   GetAllDetails()
}
James Z
  • 12,209
  • 10
  • 24
  • 44
  • show what's in your GetAllDetails method? – Fan Ouyang Aug 17 '15 at 05:14
  • GetAllDetails method returns all the details in the ScanDetailsTable as IQueryable. its just select * from TransactionTable as IQueryable – Vivekanand V V Aug 18 '15 at 04:48
  • You need to show the full method. This one does not even return a value. In Web API 2.0 you can change the attribute to `[Queryable(PageSize=100)]` to always performe a pagination. – Jan Hommes Aug 18 '15 at 13:02

0 Answers0