# How to select which db to use on Login

**URL:** <https://community.auth0.com/t/how-to-select-which-db-to-use-on-login/6940>\
**Category:** Get Help\
**Tags:** connections\
**Created:** [June 7, 2017, 3:17am UTC](https://community.auth0.com/t/how-to-select-which-db-to-use-on-login/6940 "2017-06-07T03:17:10Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jlares](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@jlares](https://community.auth0.com/u/jlares)\
**Post date:** [June 7, 2017, 3:17am UTC](https://community.auth0.com/t/how-to-select-which-db-to-use-on-login/6940/1 "2017-06-07T03:17:10Z")

</div>

I have two db connections with auth0: connectionA and connectionB

at some point in my app I want to have a radial button asking the user whether they want to authenticate as an A user or a B user. For particular reasons, i dont want to merge this two database connections.

I am using Auth0 widget to authenticate. My application is connected to both databases in the auth0 page.

How do i choose to which db to authenticate against when the user presses login in my app?

---

<div class="post-metadata">

**Author:** ![prashantT](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/prashantt/32/6002_2.png) [@prashantT](https://community.auth0.com/u/prashantT)\
**Post date:** [June 7, 2017, 6:25am UTC](https://community.auth0.com/t/how-to-select-which-db-to-use-on-login/6940/2 "2017-06-07T06:25:24Z")

</div>

If your radio button asks for the user type before showing Lock, you can then specify the connection when showing Lock as follows:

```
lock.show({connections: 'YOUR_CONNECTION']});

```

> **[Select from Multiple Connection Options](https://auth0.com/docs/libraries/lock/selecting-from-multiple-connection-options)**
>
> How to select different connection types for multiple login options with Lock V11.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [March 2, 2018, 5:54am UTC](https://community.auth0.com/t/how-to-select-which-db-to-use-on-login/6940/3 "2018-03-02T05:54:26Z")

</div>


