public Expression VisitSqlEntityExpression (SqlEntityExpression expression)
{
if (_currentContext == SqlExpressionContext.SingleValueRequired)
{
string message = string.Format (
"Cannot use an entity expression ('{0}' of type '{1}') in a place where SQL requires a single value.",
FormattingExpressionTreeVisitor.Format (expression),
expression.Type.Name);
throw new NotSupportedException (message);
}
return expression; // rely on VisitExpression to apply correct semantics
}