[dev] unique sql fix