This is one of those things that you’ll hardly ever run into. But if the stars are aligned just right, and you are running into this error perhaps this posting will help.
First of all, I’m assuming you’ve already checked the permissions of the account you are using to run this command, and as far as you can tell all the necessary permissions are in place both on the DB Server and the WFE server.
So when are the stars aligned just right?…… If you are running SharePoint 2003 and MOSS 2007 on the same server, each version is configured to use a different database server, and the account you are using to run the command does not have necessary permissions on the SharePoint 2003 database server. Why would you need permissions on the SharePoint 2003 database server, if you are trying to add a content database to your MOSS 2007 Server Farm? Perhaps is a bug, perhaps is a feature, perhaps is by design; I wont pretend to know. But we can make an educated guess by looking at the logs.
Open the logs and look for any errors generated around the same time you ran the command. If you carefully follow the trail of the error you should see some references to the following methods; get_CanUpgrade and ReflexiveCanUpgrade. These will be shortly followed by a connection string to the SharePoint 2003 Database Server, specifically the configuration database. Based on this information we can assume that MOSS wants to check if the content database being added is being upgraded from the SharePoint 2003 configuration. But why does the error occur even when the database is new? Well, MOSS doesn’t yet know that the database is new. Whatever the case may be, the fix is easy; make sure you have the necessary permissions on the SharePoint 2003 database server, or get someone who does to run the command.
BTW, a similar error will occur if adding a content database from Central Administration under the same circumstances.