The present invention provides novel sulfonamide compounds having TRPM8 antagonistic activity which are useful as medicaments. Specifically, the present invention provides a sulfonamide compound of the formula (I): wherein Ring A is the following formula (i), (ii), or (ix): R 4 is optionally substituted alkyl, X 1 and X 2 are each independently tetrazolyl, tetrazolinonyl, optionally substituted triazolyl, triazolinonyl, oxadiazolonyl, optionally substituted alkanoylaminomethyl, or optionally substituted alkylsulfonylaminomethyl, or R 4 and X 2 combine with each other at their terminals together with the adjacent benzene to form indazolinonyl or benzoisoxazolonyl, and the other symbols are the same as described in the specification, or a pharmaceutically acceptable salt thereof.