The variables m and s are the variables for each instance of Movie in the db.Movies collection "(I assume that is called a class).
Conceptually, they are similar to using sql alias m in the following sql:
select m.* from Movies m
The next time you use the where clause, you conceptually end:
select * from ( select m.* from Movies m ) s where s.Title like '%' + searchString + '%'
NOTE: this is not how sql really ends when it works with the database, just a view to help you understand.
If you look at the value of movies , you will see that it is IQueryable or the like. This means that it has not yet been completed - you have not returned anything. Thus, adding a where clause will be great - it is simply added to the query, which will be launched later.
Jon egerton
source share