Mechanistic study of chemoselectivity in Ni-catalyzed coupling reactions between azoles and aryl carboxylates.