Good day,

I having a problem where creating my setting table as condition below

column User_id setting effective_date effective_end_date
Row 1: 1 ABC 2017-03-01 2018-02-28
Row 2: 1 DEF 2018-03-01 2019-03-01

I wish to add a constraint to block if same user add in a setting with the effective_date or effective_end_date between existing setting. Is that posible?
I had searching and trying for a few days now without succeed to archive what I trying to do. Please kindly guide me through this. Thanks in advance.