Menstruation lasted a whole month. First tome this happened.50 years old. What is wrong?

Menopause. Most likely you are entering menopause. Between 45 - 55 most women go through menopause. During this time your periods may be shorter or longer than normal. If you have a family history or gyn cancers or disorders, like uterine fibroids, or are a smoker, you are at risk for tumors or other disorders. I recommend you see your doctor to make sure.
Biopsy. At the age of 50, with abnormal bleeding, it is absolutely imperative that you have a d&c(scrape of the uterus) or an endometrial biopsy(more commonly done today) to rule out a disease state that may harm you( cancer or precancer). Likely you are bleeding because your ovary did not release an egg( anovulation), often a function of age...But biopsy first.