How to Remove a Public Folder Database in Exchange Server 2007 RTM
At Exchange Support one of the most common support issue that we see is Exchange 2007 uninstall failing due to presence of Public folder replicas. When you try to Remove Exchange 2007 using the "Add/Remove Programs" from control Panel you would get an error:
The public folder database Database_Name cannot be deleted.
The public folder database specified contains folder replicas. Before deleting the public folder database, remove the folders or move the replicas to another public folder database.
You get this error because you cannot delete a public folder database that contains data. To remove data from a public folder database, delete any unnecessary public folders, and then move the remaining folder replicas in that database to a public folder database on another server. If this is the last public folder database in your Exchange organization then you should remove all public folder instances before you can remove the public folder database.
Read more at source: http://msexchangeteam.com/archive/2007/07/09/445967.aspx