Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 17 additions & 2 deletions Orm/Xtensive.Orm/Sql/Compiler/SqlCompiler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,18 @@ public virtual void Visit(SqlBinary node)
return;
}

if (node.NodeType == SqlNodeType.RawConcat) {
AppendSpace();
translator.Translate(context, node, NodeSection.Entry);
node.Left.AcceptVisitor(this);
AppendSpace();
translator.Translate(context.Output, node.NodeType);
node.Right.AcceptVisitor(this);
translator.Translate(context, node, NodeSection.Exit);

return;
}

using (context.EnterScope(node)) {
AppendTranslatedEntry(node);
node.Left.AcceptVisitor(this);
Expand Down Expand Up @@ -1385,7 +1397,7 @@ public virtual void Visit(SqlOrder node)
else if (node.Position > 0) {
_ = context.Output.Append(node.Position.ToString());
}
AppendSpaceIfNecessary();
AppendSpace();
translator.Translate(context, node, NodeSection.Exit);
}
}
Expand Down Expand Up @@ -1608,7 +1620,9 @@ protected virtual void VisitSelectFrom(SqlSelect node)
return;
}

AppendTranslated(node, SelectSection.From);
AppendSpace();
translator.Translate(context, node, SelectSection.From);
AppendSpace();

var joinedFrom = node.From as SqlJoinedTable;
var linearJoinRequired = CheckFeature(QueryFeatures.StrictJoinSyntax) && joinedFrom != null;
Expand Down Expand Up @@ -2790,6 +2804,7 @@ protected void AppendTranslated(SqlNative node)
{
AppendSpaceIfNecessary();
translator.Translate(context, node);
AppendSpaceIfNecessary();
}

protected void AppendTranslated(SqlAssignment node, NodeSection section) =>
Expand Down