You need to sign in to do that
Don't have an account?
Dynamic Soql Query
I have an object,which have an Many to many Relationships to itself using a junction object.Like..
Object 'A'
Object 'JunctionA' this has two lookups to object 'A' parent(lookup) and Child(lookup) to A.
Now Rec1
|
Rec 2 --------|_____Rec3,Rec4
|
Rec 5
|
Rec 6
Rec1,Rec2 will be related from Junction object and the same way Rec 2 and Rec 5 and so on
Now I have to write a dynamic soql query,which checks whether Rec1 has any childs if yes,query their childs and then check Rec 2 has childs and if Yes, then query them.. and so on.. as the levels of hierarchy is dynamic here..
Thanks in Advance
1) http://amitsalesforce.blogspot.com/2015/04/pagination-using-standardsetcontroller.html
Let us know if this will help you