Skip to content

Commit feb0100

Browse files
authored
Merge pull request #334 from servicetitan/fixTranslation
Merge from Upstream repo to fix Translation
2 parents 8413d82 + 372d1ea commit feb0100

20 files changed

+3589
-10450
lines changed

ChangeLog/7.1.4_dev.txt

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
[main] Addressed IndexOutOfRangeException on translation of certain queries with aggregates

Orm/Xtensive.Orm.PostgreSql/Orm.Providers.PostgreSql/DomainHandler.cs

+7
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
using System.Linq;
1010
using Xtensive.Core;
1111
using Xtensive.Orm.Rse.Compilation;
12+
using Xtensive.Orm.Rse.Transformation;
1213

1314
namespace Xtensive.Orm.Providers.PostgreSql
1415
{
@@ -21,6 +22,12 @@ public class DomainHandler : Providers.DomainHandler
2122
protected override ICompiler CreateCompiler(CompilerConfiguration configuration) =>
2223
new SqlCompiler(Handlers, configuration);
2324

25+
protected override IPreCompiler CreatePreCompiler(CompilerConfiguration configuration)
26+
{
27+
var decimalAggregateCorrector = new AggregateOverDecimalColumnCorrector(Handlers.Domain.Model);
28+
return new CompositePreCompiler(decimalAggregateCorrector, base.CreatePreCompiler(configuration));
29+
}
30+
2431
/// <inheritdoc/>
2532
protected override IEnumerable<Type> GetProviderCompilerContainers()
2633
{

0 commit comments

Comments
 (0)