Skip to content

Commit 10aebeb

Browse files
authored
Translate DateTime.Date without type mapping in legacy mode (#3032)
Fixes #3031
1 parent e9f1ded commit 10aebeb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/EFCore.PG/Query/ExpressionTranslators/Internal/NpgsqlDateTimeMemberTranslator.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ public NpgsqlDateTimeMemberTranslator(IRelationalTypeMappingSource typeMappingSo
6767
switch (instance)
6868
{
6969
case { TypeMapping: NpgsqlTimestampTypeMapping }:
70-
case { TypeMapping: NpgsqlTimestampTzTypeMapping } when NpgsqlTypeMappingSource.LegacyTimestampBehavior:
70+
case { } when NpgsqlTypeMappingSource.LegacyTimestampBehavior:
7171
return _sqlExpressionFactory.Function(
7272
"date_trunc",
7373
new[] { _sqlExpressionFactory.Constant("day"), instance },

0 commit comments

Comments
 (0)