-- remova duplicatas se necessário e depois:
ALTER TABLE RoomingNights
ADD UNIQUE KEY uq_rooming_business (originNumber, endOfDayDate, roomId);




ALTER TABLE OccupationInventoryRoomTypes
ADD UNIQUE KEY uq_inv_roomtype (occupationInventoryId, roomTypeId);
