Canonical functions in LinqConnect with Oracle

Discussion of open issues, suggestions and bugs regarding LinqConnect – Devart's LINQ to SQL compatible ORM
Post Reply
AndEx
Posts: 1
Joined: Wed 11 Jul 2018 06:44

Canonical functions in LinqConnect with Oracle

Post by AndEx » Fri 13 Jul 2018 18:06

Hello,

does LinqConnect support canonical functions or some equivalent of them?

In particular, I need to compare the year-parts of date fields with LINQ against an Oracle database.

thank you for any advice,
Andrzej

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Re: Canonical functions in LinqConnect with Oracle

Post by Shalex » Tue 17 Jul 2018 09:46

does LinqConnect support canonical functions or some equivalent of them?
The term "canonical functions" originates from Entity SQL (used in Entity Framework), for example: https://msdn.microsoft.com/en-us/librar ... .100).aspx.
In particular, I need to compare the year-parts of date fields with LINQ against an Oracle database.
Try this way:

Code: Select all

var result = context.Emps.Where(e => e.Hiredate.Year == 2008).ToList();

Post Reply