To simplify things and help our users to be more productive, we have archived the current forum and focus our efforts on helping developers on Stack Overflow. You can post new questions on Stack Overflow or join our Discord channel.
A ValueChangeListener gets informed whenever a row is added or removed. There you could check your constraint and remove duplicate rows if necessary. You just need to be aware that removals from ValueChangeListener will trigger a ValueChangeEvent themself - so look out for infinite loops (although I do not expect one from your problem-description).