+ Start a Discussion

Required Fields Left Blank?

I have a case record type with 3 page layouts.  The Type field is required on all of the page layouts, and is a controlling field for a custom field called Request Reason.  This field is also required on all page layouts.  However, every once in awhile (not very often), cases are saved, submitted and even closed and the Request Reason field is not completed.  We don't find out about it until we pull reports, but I can't figure out how this is happening.  How would someone be able to save a record without filling in a required field?


I am tracking history on this field, and the history shows no changes to that field.  There is no common thread that I can see betweeen three records that I found within a month's time that came through without the field completed.

Ritesh AswaneyRitesh Aswaney

If this is only required at the PageLayout level, and you had data feeds in either via the Dataloader or an interface, then the mandatory check won't be enforced. PageLayout restrictions dont apply to API users. However field level security and validation rules do apply in all cases.

Shashikant SharmaShashikant Sharma

I think the reason can be record being created

1)Data Loader

2)Any other controller class if you have please check

3)Debug Log (Anonymous Script in debug log)


The solution to this willl be that create avalidation rule as well for the required fields or use trigger for validation.

Validation rule is preferable.By this you will not be able to insert any record without these req fields in an case.


Thanks ... but there was no data loader or other data feed ... these were created manually.  Any other thoughts?


The cases may be Web to Case, Email to Case, or an API creation (Connect for Outlook comes to mind). Yuo can't bypass layout requiredness through the browser UI, but the API isn't bound to those limits. Take a look at the cases; like those above me, I'm sure someone is using the API somewhere, or that they are coming in through an external portal (not necessarily the Data Loader). Also, make sure your Close Case layout(s) also have the field displayed and required. When using the browser UI, they will then be required to fill out the field. If you're still convinced that it's being done manually, contact that person directly. Ask them how they're creating cases. You may not even be aware that they're using Connect for Outlook (check their login history).


Thanks so much for your quick response!  Unfortunately, our company doesn't have any web-to-case or email-to-case functionality (although we do want to turn that on eventually).  I thought maybe the Outlook thing, since we just switched from Lotus Notes to Outlook ... but hadn't turned on Connect for Outlook yet.  Figured maybe they figured it out on their own --- but the login history(s) show only Application logins.   I had contacted them before coming to you, and they assure me that they do everything the same way, all the time (isn't that ALWAYS what they say?).


So here's another question ... let's assume that the field WAS filled in at save, edit and close.  What could happen AFTER THE FACT that would remove that value?  I checked and the picklist values are still active in the list and on the Record Type and the dependencies haven't changed.  We did make some additions to the Request Reason picklist value this month ... but I don't see why that would change anything.


So is there anything we could have done after the fact from an administration standpoint (again, there's been no external API going on) that would affect the value of that field?


Unless you delete a picklist value and replace it with "none", there wouldn't be any change. Even modifying the master-slave definition of dependent picklists or record types wouldn't alter records that are already in place. While it's possible to violate page layout requiredness with customization, it seems only remotely possible that it happened that way, especially if the changes appear sporadic. Do you have any integrations or third party applications installed or running against your organization? Try using Setup > Manage Users > Login History, download the entire six months of history, and scan through it for API logins. You should be able to narrow down the cause by this means.


Here's a non-exhaustive list of things that could alter the picklist value after the fact:


API integrations (Excel Connector, Connect for Outlook)

Workflow Field Updates

Workflow Outbound Messaging (via external API integration)

Before <event> triggers on cases

Before or after <event> triggers on related records that update the cases

Asynchronous Apex Code
Batch Apex Code

Import Wizard (?)

Email to Case


That should be pretty complete. The total login history may be useful, as well as the setup screens for email services, email to case, workflow field updates, and apex trigger list.


Not sure what else to suggest here, but I hope I gave you some new ideas for what to look for.