This project has moved. For the latest updates, please go here.


Support all Edm canonical functions


The mmdb doesn't support some really basic functions, like String.IsNullOrEmpty or DateTime.Compare.

Is there some kind of workaround for this, or are these functions planned to be included? My codebase is just littered with these two functions, which renders Effort useless in my use case. :(


tamasflamich wrote Aug 28, 2012 at 10:23 AM

I am aware of the lack of complete EDM function mapping in Effort, it is indeed planned to be fixed.

If you wanted to continue testing the library, you could add additional Edm function support in the following class:

Its implementation seems a bit messy, so I will probably redesign it completely.

You can find a complete list of EDM functions here:

eatfrog wrote Aug 28, 2012 at 10:48 AM

Awesome. Thanks for the quick response. :)

I've been planning to help you out with this project, but it's been difficult to find the time recently. I'll try to take a look at this at some point in the near future.

okiaconvit wrote Oct 20, 2012 at 5:41 AM

First of all, I wanted to say that this is awesome tool for unit testing. However, there is some errors what make me confused, such as:

"There is no matching CLR function in MMDB for function Edm.IndexOf."

As I know, the mmdb does not support IndexOf function, also, I downloaded the code you refer to. But forgive my knowledge, I do not know the way how to add addtional Edm.IndexOf function. I will appreciate that if you can give me a hand, thanks in advance.

tamasflamich wrote Oct 20, 2012 at 2:16 PM

A contributor has been working on this (along with other things) for a while, you can check his implementation at his fork repository:

realstrategos wrote Jul 22, 2013 at 9:18 PM

I am having a real issue attempting to implement bitwise operators

The closest I could figure out was something like this, but I cant get it working
public static int BitwiseAnd(int a, int b)
            return a & b;
this.mappings["Edm.BitwiseAnd"] = (f, args) =>
                    FindMethod(typeof(DbFunctions), "BitwiseAnd", typeof(int), typeof(int)),
really struggling with this, any help would be greatly appreciated

tamasflamich wrote Jul 26, 2013 at 2:18 PM

I will take a look at this as soon as I can.

realstrategos wrote Aug 2, 2013 at 5:37 PM

Thanks for looking at this, my testing project plans have been put on hold until I can get past this last hurdle

realstrategos wrote Aug 12, 2013 at 8:15 PM

Has there been any update to this yet? Still stalled ...

Cant wait to write the new tests and to speed up my existing tests!

tamasflamich wrote Aug 13, 2013 at 11:03 AM

Yes, sorry for not sending a notification.

Check most recent source code or nightly builds.

memark wrote Apr 27, 2014 at 4:47 PM

What is the status right now? Are these functions still not supported?

realstrategos wrote Aug 22, 2014 at 1:33 PM

I just opened an issue as it appears that it attempts to do the operations but fails