You need to sign in to do that
Don't have an account?
s9
pageblocktable
Hi
I have 3 objects that are Loan,Candidate,Position,the Loan object have Candidate and Postion lookup relationship now how to display these three objects data by using pageblocktable .
Thanks
Ram
Hi,
Can you please explain the requirement in detail?
Becuase it is not clear that you need to show three objects data in a seperate pageblocktable/in a single pageblock table using the lookupid alone?
Also, explain in what related manner you need show the pageblock table?
Hope so this helps you...!
Please mark this answer a Solution and please give kudos by clicking on the star icon, if you found this answer as helpful.
All Answers
Hi,
Can you please explain the requirement in detail?
Becuase it is not clear that you need to show three objects data in a seperate pageblocktable/in a single pageblock table using the lookupid alone?
Also, explain in what related manner you need show the pageblock table?
Hope so this helps you...!
Please mark this answer a Solution and please give kudos by clicking on the star icon, if you found this answer as helpful.
Hi,
Sometimes we need list of all the child records of a parent record. For example we may need all the contacts of a account.
These records can be retrieved using relationship query. You can say it to be a query within a query. Before we write a relationship query,
We need to know more about lookup field. every look up field will have a child relationship named assigned to it. we can change this name as desired.
Go through the below code like as a your scenario
public class testing
{
public List<Account> acc{get;set;}
public testing(ApexPages.StandardController controller)
{
acc = new List<Account>();
acc = [Select Id,Name,(Select Id,name From contacts) From Account limit 10];
}
}
<apex:page standardController="Account" extensions="testing">
<apex:form>
<apex:pageBlock>
<apex:pageBlockTable value="{!acc}" var="a" border="1">
<apex:column value="{!a.name}"/>
<apex:column>
<apex:pageBlockTable value="{!a.contacts}" var="con" border="1">
<apex:column value="{!con.Name}"/>
</apex:pageBlockTable>
</apex:column>
</apex:pageBlockTable>
</apex:pageBlock>
</apex:form>
</apex:page>
For more detailed information look at the fallowing link
http://cloudforce4u.blogspot.in/2013/06/sometimes-we-need-list-of-all-child.html
and if you have any more questions please feel to contact me on support@groundwireconsulting.com
Hi
Position and candidate are lookup fields in loan object,now i want to display loanname ,postionnumber and candidatename in single pageblocktable.
thanks Ramesh