How to connect to an AAS model via Visual Studio Code again after it has been renamed

Clare 0 Reputation points
2023-10-26T09:15:06.1633333+00:00

I have an Analysis Services Model that was created on visual studio, which was then deployed onto Azure. I tried to rename this model via SQL Server Management Studio, and this seems to be fine and the new name appears when I view the model on the Azure Portal. (But when I view the properties of the model on SSMS, the ID field is still the old name which I can't change)

However, when I try to open the model (in tabular view) on visual studio again, I am getting the error: An error occurred while opening the model on the workspace database. Reason: Another 'Database' object has the 'Old_Name_Of_The_Model' ID.

The model is an import model, so preferably I'd want a way of accessing the project on visual studio without having to re-import the data. I have a backup of the model (Azure Blob Container), but I haven't tested this backup file yet.

Azure Analysis Services
Azure Analysis Services
An Azure service that provides an enterprise-grade analytics engine.
479 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Amira Bedhiafi 33,071 Reputation points Volunteer Moderator
    2023-10-26T12:02:01.39+00:00

    Can you try to locate the .bim file in your project folder. Try to open it with a text editor like Notepad++ or Visual Studio Code and check the Database section.

    You should find something similar to "id": "Old_Name_Of_The_Model".

    Update the id with the new name to make it consistent with the new name you used in SSMS and Azure portal and save the changes.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.