You need to sign in to do that
Don't have an account?

How to avoid duplicate data entry?
Hi,
I am seraching the students by Student Name.
Query: select Name,Student_Name__r.External_Student_Id__c, Year__c, School_Name__r.School_Name__c, Student_Name__r.Student_First_Name__c, Student_Name__r.Student_Last_Name__c from Student_Academic_Class__c where Student_Name__r.Student_First_Name__c =: student;
Need Student Name, School name from the above query without duplicate entry.

Student Name: Test (Link)
It showing Student data based on Class Name count. In the above example Student link TEST have three class.
How to avoid duplicate entry of Student ?.
Thanks
Sivasankari M
I am seraching the students by Student Name.
Query: select Name,Student_Name__r.External_Student_Id__c, Year__c, School_Name__r.School_Name__c, Student_Name__r.Student_First_Name__c, Student_Name__r.Student_Last_Name__c from Student_Academic_Class__c where Student_Name__r.Student_First_Name__c =: student;
Need Student Name, School name from the above query without duplicate entry.
Student Name: Test (Link)
It showing Student data based on Class Name count. In the above example Student link TEST have three class.
How to avoid duplicate entry of Student ?.
Thanks
Sivasankari M
You have to process your list which has duplicate entries in a loop.
You cannot do it in a query as we do in SQL like DISTINCT.
Thanks and Regards
Sandhya