A 62-year-old man suffering from a suspected heart attack waited nearly two days in casualty before a south Wales hospital could find him a bed.
Ron Williams, of Aberdare, went to accident and emergency at Prince Charles Hospital, Merthyr, on Sunday night.
He spent two nights on a trolley and some hours in a wheelchair before being found a bed on Tuesday afternoon.
The hospital apologised, and blamed exceptional emergency admissions.
Mr Williams is calling on the new Welsh health minister, Dr Brian Gibbons, to improve the system for admitting patients.
Doctors at Prince Charles suspected he may have had a heart attack, and later that he had a blood clot on the lungs.
They gave him tests but were not able to find him a bed - he spent the first night on a trolley in a resuscitation area, before being switched to a trolley in an examination room.
However, on Tuesday the trolley was needed, and he was moved to wheelchair in the middle of a casualty unit and finally given a bed in the afternoon.
Mr Williams' wife, Dianne, said the hospital was stretched
Mr Williams told BBC Radio Wales: "I was told that I was 20-21st on the list for a bed on Sunday.
'Sort it out'
"I was told last night (Monday) there were eight in front of me. I had my dinner on a tray in a corridor.
"Its a total lack by the NHS trust of duty of care to the individual.
"The staff are absolutely brilliant but the system is totally wrong."
He said Dr Gibbons must "completely sort it out - put things back where they should be".
The hospital aims to admit 95% of patients within four hours
His wife Dianne said: "There are no beds, they're understaffed, the patients just keep coming in and there are trolleys everywhere."
Dr Terry Morris, hospital medical director, said: "We and other hospitals throughout south Wales are often faced with bed shortages and this is the typical time of year for it to happen in January.
"Since the new year we've faced a very high number of emergency admissions and I understand it's the highest we've had for five years."
Prince Charles has a policy that 95% of people admitted via casualty should be found a bed within four hours. The average wait at present is 10 hours.
An assembly spokeswoman said: "The majority of patients are seen quickly in Welsh hospitals. But we want even more patients to be seen quickly which is why we are continuing to work on improving emergency care.
"All trusts in Wales have plans in place to deal with busier times including the use of beds in neighbouring trusts if necessary."