thanks for the pointer. I was doing it the different way around. Creating a materialized view that contained the function as a column and creating a unique key on that materialized view. Talk about the long way around ;-), this will make it a lot ‘smoother’.