Facebook might be stripping or blocking certain url parameters when sharing the link, which could be why the email parameter isn’t being recognized. Since reading directly from the database works without parameters, the issue is likely with how facebook handles the url when shared.

One workaround is to encode the email before passing it in the url. You can try using :formatted as text in bubble to Base64 encode the email before adding it as a parameter. Then, on the receiving page, decode it before using it in a search.

Another option is to store the email in the database when the user first lands on the page and then reference that stored value instead of relying on the url parameter. So, even if facebook alters the url, the app can still retrieve the correct user data.

If facebook is blocking emails in the url for privacy reasons, you might need to pass a unique id instead of the email, then use that id to find the corresponding record in the database.