Class RowNumberExpression
- Namespace
- Microsoft.EntityFrameworkCore.Query.SqlExpressions
- Assembly
- Microsoft.EntityFrameworkCore.Relational.dll
An expression that represents a ROW_NUMBER operation in a SQL tree.
This type is typically used by database providers (and other extensions). It is generally not used in application code.
public class RowNumberExpression : SqlExpression, IPrintableExpression
- Inheritance
-
RowNumberExpression
- Implements
-
IPrintableExpression
- Inherited Members
Constructors
RowNumberExpression(IReadOnlyList<SqlExpression>, IReadOnlyList<OrderingExpression>, RelationalTypeMapping)
Creates a new instance of the RowNumberExpression class.
public RowNumberExpression(IReadOnlyList<SqlExpression> partitions, IReadOnlyList<OrderingExpression> orderings, RelationalTypeMapping typeMapping)
Parameters
partitions
IReadOnlyList<SqlExpression>A list expressions to partition by.
orderings
IReadOnlyList<OrderingExpression>A list of ordering expressions to order by.
typeMapping
RelationalTypeMappingThe RelationalTypeMapping associated with the expression.
Properties
Orderings
The list of ordering expressions used to order inside the given partition.
public virtual IReadOnlyList<OrderingExpression> Orderings { get; }
Property Value
Partitions
The list of expressions used in partitioning.
public virtual IReadOnlyList<SqlExpression> Partitions { get; }
Property Value
Methods
Equals(object)
public override bool Equals(object obj)
Parameters
obj
object
Returns
GetHashCode()
public override int GetHashCode()
Returns
Print(ExpressionPrinter)
protected override void Print(ExpressionPrinter expressionPrinter)
Parameters
expressionPrinter
ExpressionPrinter
Update(IReadOnlyList<SqlExpression>, IReadOnlyList<OrderingExpression>)
Creates a new expression that is like this one, but using the supplied children. If all of the children are the same, it will return this expression.
public virtual RowNumberExpression Update(IReadOnlyList<SqlExpression> partitions, IReadOnlyList<OrderingExpression> orderings)
Parameters
partitions
IReadOnlyList<SqlExpression>The Partitions property of the result.
orderings
IReadOnlyList<OrderingExpression>The Orderings property of the result.
Returns
- RowNumberExpression
This expression if no children changed, or an expression with the updated children.
VisitChildren(ExpressionVisitor)
protected override Expression VisitChildren(ExpressionVisitor visitor)
Parameters
visitor
ExpressionVisitor