Forum Discussion
Fabric activity(Notebook) failed. 'An item with the same key has already been added.
- 6 months ago
Hello Siva I'm guessing you're using a SPN for the notebook connection. Have you switched to SPN based connection recently? It is quite possible that you're experiencing this problem because the SPN you used in the connection have been used somewhere else.
If there are multiple Connections referencing the same SPN (or duplicate parameter keys/headers in the activity), Fabric can throw 2015 / duplicate key at runtime.If possible, create a new SPN and try again, and let us know how it went!
Hello Siva I'm guessing you're using a SPN for the notebook connection. Have you switched to SPN based connection recently? It is quite possible that you're experiencing this problem because the SPN you used in the connection have been used somewhere else.
If possible, create a new SPN and try again, and let us know how it went!
Hi deborshi_nag
Thank you for your response. I tried deleting the existing connection and creating a new one, however this did not resolve the issue. Since the connection for the Notebook activity is not mandatory, I removed the connection configuration and the pipeline executed successfully afterward.
- deborshi_nag6 months ago
Super User
Hello SivaReddy24680
Once the Fabric Connection is created and bound to the current notebook, you can generate code snippets to access the data source directly from the notebook.
Fabric Connection with Notebook - Microsoft Fabric | Microsoft Learn
Can you try this please.
- SivaReddy246806 months ago
Advocate I
Thank you again, this is helpful.
But my notebook only reads parquet files from the Lakehouse. As a workaround, I removed the connection configuration since it is not mandatory in this case. The notebook and the pipeline are both in the same workspace and after removing the connection the pipeline executed successfully.