Implemented ghost id and num