You need to sign in to do that
Don't have an account?
Santosh Reddy9989
how to check the FLS of parent object's field in Child to Parent query ?
Hi,
query : Select Id, Name, Email, Account.Name, Account.Industry from Contact
For Id, name and Email fields, we use below code for FLS check
SObjectType childobje = Schema.getGlobalDescribe().get('Contact');
childobje.getDescribe().fields.getMap().get('Name').getDescribe().isAccessible();
childobje.getDescribe().fields.getMap().get('Email').getDescribe().isAccessible();
if i use childobje.getDescribe().fields.getMap().get('Account.Industry').getDescribe().isAccessible() then i am getting "NullPointerException de-reference a null object" exception.
How to check the FLS for Account.Industry from contact object ???????
Thanks,
Santosh Reddy
query : Select Id, Name, Email, Account.Name, Account.Industry from Contact
For Id, name and Email fields, we use below code for FLS check
SObjectType childobje = Schema.getGlobalDescribe().get('Contact');
childobje.getDescribe().fields.getMap().get('Name').getDescribe().isAccessible();
childobje.getDescribe().fields.getMap().get('Email').getDescribe().isAccessible();
if i use childobje.getDescribe().fields.getMap().get('Account.Industry').getDescribe().isAccessible() then i am getting "NullPointerException de-reference a null object" exception.
How to check the FLS for Account.Industry from contact object ???????
Thanks,
Santosh Reddy
childobje.getDescribe().fields.getMap().get('Industry').getDescribe().isAccessible()