Declared panel data as xtset year (instead of xtset panelid year)

xtset YEAR
panel variable: YEAR (balance
d)

. xtreg logXijt logGDPitGDPjt logPCGDPitPCGDPjt logPCGDPDijt TRGDPit TRGDPjt logDistanceij Borderij i.PanelIDIndoASEAN, fe
Is it correct way of computing country wise fixed effects?

.reg logXijt logGDPitGDPjt logPCGDPitPCGDPjt logPCGDPDijt TRGDPit TRGDPjt logDistanceij Borderij i.PanelIDIndoASEAN. This is also countrywise fixed effect command.

I was told to give command in point 2 for countyrwise fixed effect and now I am confused if it is possible? Please answer this query

Regards
Saba Gulnaz