The solution ChatGPT keeps giving uses a clause `where ` on `UniqueConstraint` that does not exist. Telling the AI it gives an exception helps it to fabricate other non working solutions. Fortunately StackOverflow saves the day.