function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Stefano AmentaStefano Amenta Site user unable to lookup records


Here's the issue I'm currently facing:

I have created a visual flow and hosted it on a site page so that it can be accessed by a guest user profile. One of the functions of this flow is the possibility to "record lookup" from the contacts object: the guest user can input the Contact ID in the flow and he will be able to see basic info of the contact such as name, email, country.

I tested this flow in the Sandbox and it was working perfectly. But when I deployed it to our QA org, the guest user is unable to find any contact record (even though the record exists in QA org).

In QA org I went through all these steps:

1. I checked that the guest user has READ / CREATE access to Contacts, Accounts and my custom object
2. I checked that the guest user has access to all the relevant fields across the objects
3. I checked the Sharing Settings: both in Sandbox and QA, the Accounts object is set to "Private" and Contacts is set to "Controlled by Parent". However, I have no idea why it works in Sandbox but not in QA. As far as I know, it seems it's not possible to create a sharing rule with a guest profile.
4. I checked that the guest user has access to the correct Contact record type (if that matters at all).

At this point, I'm lost and stuck with my project :(

Do you know what could prevent the guest user from looking up a contact record through the visual flow?

Thanks a million for any advice you might have.
Parteek Goyal 3Parteek Goyal 3
Hi Stefano,

This is happening just because of access level of site profile.

Please go to that specific "Site" then go "Public Access Settings" and check the access of belonging objects and fields.
if it is already checked then uncheck all checkboxes and then again enable them and save it.

Stefano AmentaStefano Amenta
Hi Parteek,
thanks for the suggestion.

I did exactly as you suggested me but unfortunately I'm still facing the problem.

The Guest User profile has READ and CREATE access to Contacts and Accounts, and it has READ / EDIT permissions on any fields in those objects.

It's really puzzling that it can't lookup the record :-/
NagendraNagendra (Salesforce Developers) 
Hi Stefano,

Please check it by setting Contact as private and check whether it is working or not. When the child is controlled by the parent I mean contact is controlled by account and if the account record is not shared with the guest then he will not be able to see even if he has created the same.

Stefano AmentaStefano Amenta
Hi Nagendra

Thanks for the answer.

I have set Contact as private but I'm still facing the problem.

Do you know how I can share Account or Contact with a guest user profile?

In Sandbox org the Account is private and Contact is controlled by parent, however the record lookup in the flow works perfectly.

In QA org the Account is private and Contact is also controlled by parent, but the record lookup doesn't work.

Really strange.
Jessica Chevalier 7Jessica Chevalier 7
Hi Stefano,

Did you find a resolution to this? I'm running into the same issue and I'm stumped. Thanks in advance! 

学习 李学习 李
hi @Stefano and @Jessica

Added the 'Search Pages' And 'Look Up Page' under the Site Standard Pages section in Site Detail Page, and it worked.

hope it help you
Prashant Patil 65Prashant Patil 65
Facing same issue i have created custom lookup and masterdetails fields but not getting values in sites otherwise VF page works fine 
But in using it in sites not populating values. I have added search page & lookup page to site standerdPage but still same issue