Table of Contents

Class PivotValue

Namespace
NextORM.Core
Assembly
nextorm.core.dll

One value of the PIVOT ... IN (...) list. The value names the resulting column, so select it in the projection under the desired name (for example .Select(t => new { Q1 = SqlFunctions.Column<decimal?>(t, "1") }): the value is a raw name and is always safely quoted, so a value that is not a plain identifier is still one identifier).

public sealed class PivotValue
Inheritance
PivotValue
Inherited Members
Extension Methods

Properties

Value

The source value matched by this pivot column; also the resulting column's name.

public string Value { get; }

Property Value

string

Methods

Create(string)

Creates a pivot value. The string is the raw data value matched against the FOR column and the resulting column's name: it is emitted as one safely quoted identifier, independently of the command's QuoteIdentifiers option, and is never normalised, trimmed or stripped. So "a]b" keeps the data value a]b (rendered [a]]b] on SQL Server) and "[1]" is not silently reinterpreted as 1.

public static PivotValue Create(string value)

Parameters

value string

Returns

PivotValue