+ Start a Discussion
sfpsfp 

In security scanner, got the warning Queries_With_No_Where_Or_Limit_Clause?

Hi All,

Query Name - Queries_With_No_Where_Or_Limit_Clause
Severity - Warning
17. public void loadUserList() //userlistcontroller.cls
18. total_size = [SELECT count() FROM User__c];

Please help out this issue.

Kind Regards,
Mohan
sfpsfp
I have added the query like this Where clause. 
SELECT count() FROM User__c WHERE Id != null

Is it okay, I guess. 
 
Neetu_BansalNeetu_Bansal
yes