Corey
Posts: 13
Joined: Tue Mar 25, 2014 4:54 am

Browse Databases Custom Action

Hi,
I am trying to use a combo box to select a database from a list based on the user supplied. Currently I have the SQL authentication working well, however trying to pass a domain\user fails.

I do not want to use a trusted connection as this is a Local connection and I am trying to conect to a remote instance. Is there anyting that I need to do to complete this. I have followed this http://www.advancedinstaller.com/user-g ... bases.html tutorial.

Also would like the DataBase selector on the same page as User/Password if possible, I have tried a button which will set the USERNAME_PROP and PASSWORD_PROP and SERVERNAME_PROP with the custom action defined as last in the list.
Daniel
Posts: 8283
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Browse Databases Custom Action

Hello,

Just to make sure I fully understand your scenario, your installation scenario is the following:
1. run the setup package under a local user account
2. try to browse for SQL databases using Windows Authentication for a domain user account

If this is the case, I'm afraid you cannot achieve what you want. If you are not setting the "SqlTrustedConnection" property, then the SQL connection will use the SQL Server authentication (therefore if your set the "USERNAME_PROP" and "PASSWORD_PROP" properties the SQL connection will try to connect with the above credentials as SQL credentials). If the "SqlTrustedConnection" property is set then the SQL connection will use the Windows Authentication for the current logged on user (and the "USERNAME_PROP" and "PASSWORD_PROP" properties will be ignored).

So, using our browse for SQL databases support the only way to browse for databases of a domain user account would be by logging under the related domain user account, running the setup package and setting the "SqlTrustedConnection" property to 1.

Let us know if this helped, otherwise please give us more details about your scenario.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
Corey
Posts: 13
Joined: Tue Mar 25, 2014 4:54 am

Re: Browse Databases Custom Action

Hi Dan,
Yes this is what I am trying to achieve, Will just have to leave it at an edit box as we use the domain user to set the app pool identity with Integrated security or set the username / password in the web.config for SQL security. Would be a good enhancement for advanced installer

Return to “Common Problems”