Custom database not being checked

I have enabled a custom database on my tenant, toggled on “Import Users to Auth0” and “Use my own database”, and I’ve connected the app that should use it.
I’ve added scripts for Login and GetUser, and the scripts succeed when I test. I’ve used the “Try” option, and the also succeeds.
But when I attempt to log in to the web application with a user who is in the legacy database but not in Auth0, I get a “Wrong email or password” error, and no logs in my custom database that indicate Auth0 attempted to connect to it.
Is there an additional setting I’m missing to force Auth0 to use the custom database as the backup?

1 Like

Heya @codavis,

It sounds like you’ve configured things correctly, I would recommend installing the Realtime Webtasks extension and adding console.log debugging lines into your scripts to help see what is going on during the flow.

There may be something behaving not as expected in the script throwing the error, or a conflict with rules/hooks if you have any enabled.

If the Custom DB scripts aren’t being called, I would recommend checking you don’t have more than one database enabled for the app, as Auth0 may be defaulting to another database - please see here for some more details if you need to have more than one database connection enabled for the app: https://auth0.com/docs/libraries/lock/v11/selecting-the-connection-for-multiple-logins

5 Likes

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.