Reduce IN_MAX by number of columns in UNIQUE validation

issue3230
review934002
(transplanted from 86c84d68b8b0364c5d80becc7aa1df0ae10be55f)

--HG--
extra : transplant_source : %86%C8Mh%B8%B06L%5D%80%BE%CCz%A1%DF%0A%E1%0B%E5_
Fix encoding domain names with trailing dot

review949002
(transplanted from bd595c644022b75f8bd73dcfef7c0379fd4ec9ba)

--HG--
extra : transplant_source : %BDY%5Cd%40%22%B7_%8B%D7%3D%CF%EF%7C%03y%FDN%C9%BA
Fix child_of in referenced search on Many2One and Reference fields

review953002
(transplanted from df20938c0b023010c65258c251e32b348b3e8fe3)

--HG--
extra : transplant_source : %DF%20%93%8C%0B%020%10%C6RX%C2Q%E3%2B4%8B%3E%8F%E3