An object of the present invention is to provide a drug having the inhibitory activity on ENPP2 which is a different target from that of the existing drug, as a medicament useful in a urinary excretion disorder patient for whom the existing drug has the insufficient effect. The present invention provides a compound represented by the general formula (I): (wherein definition of each group is as defined in the description) having the ENPP2 inhibitory activity, a salt thereof or a solvate thereof or a prodrug thereof, and an agent for preventing or treating urinary excretion disorder and/or improving symptoms thereof, containing them as an active ingredient.