I have the following data type. I have four countries with 50 companies each for three years. I was trying to create a panel but getting the error "repeated time values within panel". Below is the stata steps i have used. Can you please identify whats missing.
Sr# Country company Years SID_codes country_coding CSR annual reports other variables
1 China coA 2015 3679 1 10 1.36E+08
1 China coA 2016 3680 1 10 1.36E+08
1 China coA 2017 3681 1 10 1.36E+08
2 China coB 2015 3679 1 10 1.36E+08
2 China coB 2016 3680 1 10 1.36E+08
2 China coB 2017 3681 1 10 1.36E+08
3 India coC 2015 3679 2 4 1.36E+08
3 India coC 2016 2 4 1.36E+08
3 India coC 2017 2 7 1.36E+08
4 Bangladesh coD 2015 3679 3 5 1.36E+08
4 Bangladesh coD 2016 3 5 1.36E+08
4 Bangladesh coD 2017 3 5 1.36E+08
5 Pakistan coE 2015 3679 4 2 1.36E+08
5 Pakistan coE 2016 4 3 1.36E+08
5 Pakistan coE 2017 4 4 1.36E+08

sort country_coding Years
egen newid= group(country_coding)
xtset newid Years

error occurs in the third step
"repeated time values within panel".
r 451.

i have tried on other options too as stated below..They also dont work for me:
egen new_panelidd= group(Country SID_codes)
sort new_panelidd Years
xtset new_panelidd Years

error occurs in the third step again
"repeated time values within panel".
r 451.