Death is inevitable, but only a few people have the fortune of a graceful death. Ensuring a peaceful death to the loved one is called the Last rites. The last prayers given to the person right before the death, or to the one’s who are nearing the death or who is on the death bed.
By perfoming last rites, the soul of the person who is dying will be prepared to rest in the peace by providing absolution for all his sins by penance, sacramental grace and prayers for the relief of suffering through anointing. In the other words, by performing last rites, the soul will prepare to depart from the physical body.
Last rites are not detrimental to anybody. The family and the friends of the deceased will have the feeling of emptiness with the loss of their loved ones, and apart from them, it will not affect anybody much. And neither it will be detrimental or cause harm to anybody.
As far as I see, most of the healthcare providers do not have the culture of getting the last rites done to their patients. But if it is their well-admired patient, they may take part in the last rites. Very few healthcare providers take the step of allowing last rites at the hospital, and that trend is slowing increasing now, and healthcare providers are trying to bade goodbye/ farewell by performing last rites to its most beloved patients as a token of good gesture from their side.