I have one table where I have store my multiple DB credential.
Now I would like to use there credential to log in into MS SQL Server using loop in Knime and get data from multiple DB’s.
I tried using flow-variable but I get error saying “ERROR Microsoft SQL Server Connector Attempt to overwrite the password with config key ‘password’ failed. It’s not possible to overwrite passwords with flow variables.”
Is there any Solution to this?
Hi @RkCH and welcome to the Knime Community.
So basically you just need to create a Credentials object instead of trying to pass the username and password to the Microsoft SQL Server Connector. It’s not possible to overwrite the passwords in the connector as the message says.
You can add the Variable to Credentials node between your variable and the Connector:
You can configure the Variable to Credentials node like this:
Give a name to your credentials object, and choose the variables you are attempting to pass as username and password
You should see the Credentials object after that:
In your connector, choose Credentials, and assign the Credentials object to it:
Thank you for the providing this solution.
But now I am facing one more issue with this node AS I have said that i have to run those credentials in loop it works fine for first credentials.
Then after querying in db I faced an error.
So then loop got terminated. After solving the error I tried executing the workflow again the it giving me this error “WARN Variable to Credentials 7:55:55 Selected username variable (UserName) no longer available”.
Is there any solution for this? If yes Please guide me through that. Thank You.
Hi @RkCH , the more details you give, the more precise the solution will be.
Otherwise, this will end up into a long thread where you will provide little details by little details and with a lot of back and forth.
May be you can start by showing us what you are doing, and explain what you are trying to do?
And when you say you “tried executing the workflow again”, did you mean you resume the execution or did you reset the whole workflow and tried executing again? The warning message that you mentioned shows that it was an attempt to resume rather than restart, is that correct?
As a good practice, before you implement something in a loop, try it first without a loop to see if it works. It’s pointless to implement a loop on something that’s not working.
Thank You. I was able to solve this with your recommended method.
This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.