database ID hardcoded in XMLA
The cube database the XMLA command will impact is hardcoded in the XMLA. There should be an option such that the database it is applied to is based upon the current database for the connection (which is roughly analogous to the Initial Catalog property of the connection string). That way, the same script can be run against one (or several) databases regardless of what it is named.
With a MDX query, when you're running it in Management Studio, you have to make sure and check that you're connected to the right database or it won't work. But with XMLA commands, it ignores what database you're connected to. This seems inconsistent and has caused me to alter the wrong database several times.
If such a feature were available, it might make this issue easier to solve:
Upvotes: 1<=-=Feb 12 2007 10:23AM=-=>
Thank you for your suggestion. We will consider for the next release of SQL Server.