The Colombian Senate on Wednesday rejected a bill which would have allowed same-sex couples the right to marry.

The decision by the Senate directly defies a previous ruling by the Supreme Court that it must allow equal marriage rights to gay and lesbian couples.

The vote was 51-17 against, a day after Senators debated on the issue, and Rainbow flags were out in force in Bogota, in pro-equality demonstrations.

In 2001, the Colombian Constitutional Court issued a ruling that required politicians to ‘repair the deficit of legal protection’ for same-sex couples in the country by the 20 June 2013 or same-sex couples would be granted the right to marry. However, in 2009, a court ruled that this would not mean the right to adopt, as straight couples have the right to do.

“Marriage is a fundamental right,” said Senator Luís Carlos Avellaneda. “The principal of equality extends the same protection to all Colombians without discrimination.”

If the court fails to act on the judicial mandate by 20 June, gay and lesbian couples would be able to legally register their unions.

“We are saddened to hear Columbia’s Senate chose not to allow loving and committed gay and lesbian couples to marry. 14 countries have already taken the step to insure all families are treated equally under the law,” said Joe Mirabella, Director of Community Campaigns for All Out.

“All Out’s more than 1.5 million members urge the Colombian courts to correct this injustice when they hear a marriage case this summer”, he continued.

The Colombian Senate in 2007 also defeated a bill which could have allowed civil unions for same-sex couples to enter into civil unions.

Last year, senator Edgar Espíndola said changing the law would open the way towards necrophilia, bestiality and paedophilia. He said: “Today in the world there are many countries where bestiality is practically a sexual preference for some, or necrophilia, or paedophilia”.

He added: “We can’t copy those models,” as he lamented the trend towards “modernism” in other countries, reported the El Tiempo newspaper.

Senator Roberto Gerlein sparked outrage with a similar homophobic rant in which he described gay sex as “dirty and revolting”.