A process for preparing a compound represented by formula (Y1) or (Y2) [wherein Rx is an optionally substituted carbocyclyl lower alkyl, or the like] or a salt thereof, using a novel process for preparing a pyridone derivative represented by formula (X4) [wherein R1d is hydrogen, halogen, or the like; R2d is hydrogen, a lower alkyl optionally substituted with substituent E, or the like; R4d is a lower alkyl optionally substituted with substituent E, or the like; and R6d is a lower alkyl group optionally substituted with substituent group E, or the like].