DMN Unique Policy Default erro

I have a DMN table where I have two inputs (integer/string) and hit policy Unique, last I have set a default value. When I run this, I get an error that whatever correct input I choose, it always gives error that the results is not unique and clashes with the default.

Now, I think that this shouldn’t happen as I consider default input and the rest of the table to be unique. Is this how Unique operates or is there something else in my table causing this?

PS. I know setting hit policy to First would fix the issue, but I am mostly interested in understanding this particular case.


animal.dmn (5.5 KB)

Hi @GremlinAtTheDisco
Welcome to the forum.

You said:

Sadly this is not the case. The unique hit policy can’t ever have a default as part of the table because it will always match another field and so 2 results will be returned.
If you want a default you’ll need to use the first hit policy.

2 Likes

Hi Niall :slight_smile:

Thanks for the quick reply. Great, now I understand why this happens and that it wasn’t anything else causing some unknown error.