Drinking in public is to be strictly controlled in Edinburgh in a bid to tackle "hot spot" areas blighted by abusive drinkers.
Drinkers flouting the law face a £500 fine
The police have agreed not to stop people drinking peacefully in the streets, parks and squares when it takes effect on 8 January.
But refusal to stop drinking if asked could mean arrest and a fine of £500.
Justice Minister Cathy Jamieson said she wanted to target alcohol-related anti-social behaviour in the city.
She said a balance had to be struck between meeting tourism needs and ensuring residents a quality of life.
"I am reassured that new protocols drawn up between the police and the City of Edinburgh Council will achieve this," she said.
The 27 by-law bans already in place in Scotland cover more than 480 towns and villages, and the built up areas within the cities of Glasgow, Dundee and Aberdeen.
Under the Edinburgh by-law, anyone drinking in public would have to stop if asked by police.
Edinburgh Council leader Ewan Aitken said: "It's vital that people who live, work and visit Edinburgh feel safe on our city's streets and excessive drinking undoubtedly jeopardises that feeling of safety.
"This by-law is a real step forward in tackling the problem of on-street drinking and has been carefully worded to ensure it doesn't penalise those who drink responsibly."
City leaders hope the by-law will allow police to disperse groups of drinkers quickly and easily and prevent groups forming, defusing potential trouble before it escalates.