Firstly I would like to know about fixing the original analysis. So when you delete any dataset, the related visuals error out. However if you again add the dataset, the visuals get reloaded. What was the error when you tried this step?
As the alternate process which you suggest, updating existing dashboard with new analysis, I am aware that it is not achievable through console but through cli commands. You can refer to the solution in this query for the step by step detailed process.
thnx for that responce, i did not know adding the dataset will reestablish all the same links.
I added the old dataset again, and then replaced it with the new target dataset and its working now.
I will check also the CLI solution for any other situations.