I am migrating SharePoint 2007 publishing site to SharePoint 2010. These are the steps I have followed
1. Backup the content database from the SP2007 machine.
2. Restore that database in sql server 2008 (SP2010 machine).
3. Create a new web application in SP2010 and create a site collection type of publishing template.
4. I have run the following stsadm command for adding the content database to the web application
stsadm -o addcontentdb -url http://testsite -databasename WSS_Content_test
But I am getting the Invalid object name sites error. Could anyone help me to resolve this issue ?