The invention relates to a nicotinic acid derivative shown in the formula (I), and pharmaceutically acceptable salt or solvate thereof, wherein Z is selected from O, S and NR3, and R3 is hydrogen or C1-6 alkyl; R1 or R2 is independently selected from hydrogen, C1-6 alkyl, C1-6 alkoxy group, halogenated C1-6 alkyl, halogen, nitro, aryl, aryl oxygroup, heteroaryl, heteroaryl oxygroup, heterocyclic radical, and heterocyclic oxygroup; C1-6 alkoxy group, halogenated C1-6 alkyl, aryl, heteroaryl, and heterocyclic radical can be optionally substituted by substituent groups which can be C1-6 alkyl, C1-6 alkoxy group, halogenated C1-6 alkyl, halogen, cycano, nitro and aryl; m is an integer of 0 to 4; and n is an integer of 0 to 5. The compound or salts thereof have strong inhibition activity to colorectal cancer cell line HCT-116, human lung cancer cell line A549 and breast cancer cell line MCF-7. In addition, the compound is broad-spectrum in anti-cancer activity, and can be used as a candidate drug or a pilot compound for treating diseases of tumors, cancers and the like.