I have a database which will eventually contain thousands of records and will search this list using the Silverlight autocompletebox control and WCF RIA services. I am using the base implementation without any parameters for the "GetXXXQuery" in my domain datasource:
public IQuerable<XXX> GetXXXs()
{
return this.ObjectContext.XXXs;
}
I will be using the return value of this query in an autocomplete using the "Name" as the ValueMemberPath.
My list of objects is quite small now, so it is very fast to list all the records I have. My question is: Once my list of records becomes larger, or if more people hit the server, is this implementation efficient? Is it returning the entire list of records in my database, or is the IQueryable object somehow allowing for a query based upon the string in my autocomplete box, effectively returning a small subset of records from my database?
Thanks, Dennis