fix a bug caused by hard coded P000