ObjectQuery<T>.Top Method (String, ObjectParameter[])
Limits the query results to a specified number of items.
Assembly: EntityFramework (in EntityFramework.dll)
Parameters
- count
-
Type:
System.String
The number of items in the results as a string.
- parameters
-
Type:
System.Data.Entity.Core.Objects.ObjectParameter[]
An optional set of query parameters that should be in scope when parsing.
Return Value
Type: System.Data.Entity.Core.Objects.ObjectQuery<T>A new ObjectQuery<T> instance that is equivalent to the original instance with TOP applied.
Exception | Condition |
---|---|
ArgumentNullException | count is null. |
ArgumentException | count is an empty string. |