Prosecutors in the United Kingdom have dropped charges against two Canadian pilots accused of preparing to fly a commercial aircraft while under the influence of alcohol after their blood samples were mistakenly destroyed at a Scottish prison.

Prosecutors say there will be no further action against Imran Syed, 39, and Jean-François Perreault, 41, who were arrested July 18, 2016, before they were to pilot an Air Transat flight from Glasgow to Toronto.

Authorities say Syed, from Toronto, was alleged to have had 49 milligrams of alcohol in 100 millilitres of blood. Perreault, who is also from Ontario, was alleged to have had 32 milligrams.

Both men have denied the charges.

The flight eventually took off with a different crew the next morning after about 250 passengers spent the night at hotels.

Air Transat had suspended the pilots, but says they will be reinstated because they have been "declared innocent."

"We will be meeting with them in the next few days to plan their reinstatement since there is no charge against them and we have no evidence that they have broken any law nor our internal rules," the airline said. "They will need to undergo retraining and requalification as per applicable legislation, and we will put in place measures to ensure that their behaviour is exemplary."

Prosecutors said they are taking steps to prevent a similar loss of evidence in the future.

"We are working with Police Scotland to ensure there are proper processes and guidance in place covering the retention and storage of samples when an accused person is remanded in custody," they said.

The two were charged under a section of the United Kingdom's Railway and Transport Safety Act that precludes people from conducting aviation functions "when the proportion of alcohol in [their] breath, blood or urine exceeds the prescribed limit."

Canadian aviation regulations prohibit any aircraft crew members from working while intoxicated or within eight hours after having an alcoholic drink.

Air Transat's president said at the time that the carrier would compensate all passengers booked on the flight.

European Union rules stipulate a passenger is entitled to 600 euros ($940 Cdn) in the event a flight longer than 3,500 kilometres is cancelled.