UBS lost $356 million on Facebook, suing Nasdaq for it

UBS said Tuesday that it lost $356 million on Facebook's IPO due to Nasdaq's trading glitches during the company's market debut in May -- and it plans to sue the stock exchange for every cent of it.

"UBS's loss resulted from NASDAQ's multiple failures to carry out its obligations, including both opening the Facebook (FB) stock for trading and not halting trading in the stock during the day," said UBS in its second-quarter earnings press release. "We will take appropriate legal action against NASDAQ to address its gross mishandling of the offering and its substantial failures to perform its duties."

UBS (UBS) said it plans to pursue compensation for the "full extent" of the loss.

The bank's announcement comes just a week after Nasdaq said the $62 million accommodation fund it will use to compensate trading firms for losses incurred by Facebook's botched IPO is "definitive" and that it doesn't plan to set aside any reserves for legal expenses.

In fact, Nasdaq CEO Robert Greifeld said last week that the exchange has "substantial legal and factual defenses to any litigation that has been or could be brought in connection with this IPO."

UBS declined to comment further on the possibility it might change its mind and actually settle with Nasdaq after all. And Nasdaq declined to comment Tuesday about whether UBS would still be eligible for any compensation if it went ahead with a lawsuit.

UBS is among the four big trading firms to suffer losses because of Nasdaq's technical problems on the day Facebook made its public debut. But the Swiss bank's losses far outweigh the combined losses of its peers.

UBS said that due to Nasdaq's glitches, pre-market orders for Facebook were not confirmed until several hours after Facebook started to trade. As a result, UBS said "orders were entered multiple times before the necessary confirmations from NASDAQ were received and our systems were able to process them."

"NASDAQ ultimately filled all of these orders, exposing UBS to far more shares than our clients had ordered," UBS added.

Knight, Citadel and Citigroup have so far declined to comment on what they think of Nasdaq's accommodation plan.

Hibah Yousuf is a reporter at CNNMoney, where she covers stocks, bonds, commodities and currencies trading across the globe, as well as corporate earnings and other markets-related news. Prior to joining the site in 2009, she interned at Money Magazine.