Thankyou for using Microsoft Q&A platform and thanks for posting your query here.
As I understand your issue, you are experiencing error "The document cannot be deleted since it is reference by datasetname" while trying to delete the linked service from ADF workspace,however, you have already deleted all the reference resources. Please let me know if that's not the issue.
It seems that you might have deleted all the related resources like dataset associated with this linked service from the collaboration branch , not from the adf_publish branch. Could you please switch to the GIT mode to live mode to verify if the dataset is really deleted from the published branch or not.
Once you ensure that the related resources are deleted from the publish branch as well. Create a new collaboration branch and delete the linked service from this branch and then, merge this change to the main branch and publish it.
Hope it helps. Kindly let us know how it goes. Thanks
@Shreyash Choudhary ,
Just following up to see if the below answer helped. Please do consider clicking
Accept Answeras accepted answers help community as well. Also, please click on
Yesfor the survey 'Was the answer helpful'
@Shreyash Choudhary - Glad to know that the below response was helpful. Thank you for marking this answer as accepted. This will help others find useful answers faster.
Please feel free to take a survey on the relevant answer. You can help us improve by leaving feedback verbatim.
Have a good day!