• Phonk64
  • NEWBIE
  • 0 Points
  • Member since 2009

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 1
    Questions
  • 1
    Replies

 Hi,  I am getting the error "SObject row was retrieved via SOQL without querying the requested field: Conference__c.Technology_Types__c.  Class.SimilarConferencesController.: line 7, column 76 External entry point " when I try to launch my Visualforce page.

Here is my controller code:

 

public class SimilarConferencesController {

private final String conf_type;

public SimilarConferencesController() {
conf_type = [select id, name from Conference__c where id =
:ApexPages.currentPage().getParameters().get('id')].Technology_Types__c;


}



public ApexPages.StandardSetController setCon {
get {
if(setCon == null) {
setCon = new ApexPages.StandardSetController(Database.getQueryLocator([select id,name from Conference__c where Technology_Types__c = :conf_type]));
}
return setCon;
}
set;
}
public List<Conference__c> getSimilar() {
return (List<Conference__c>) setCon.getRecords();
}


}

 Here is the visualforce code just in case:

 

 

<apex:page controller="SimilarConferencesController" title="Conferences Like Me">

<apex:pageBlock title="Similar Conferences">
<apex:pageBlockTable value="{!similar}" var="a">
<apex:column value="{!a.name}"/>
</apex:pageBlockTable>

</apex:pageBlock>

</apex:page>

 

 

 

 I've followed the API's examples and I can't figure out what the actual problem is.  I found similar posts, but they didn't help me out very much.  Can anyone shed light on this?  I'm just trying to query the database to display Conference records whose technology type field match the source conference (its a custom link that triggers the visualforce page).

 

I feel like this is a mistake a lot of beginner's make (I'm on day 2 of APEX developement...).

 

 Hi,  I am getting the error "SObject row was retrieved via SOQL without querying the requested field: Conference__c.Technology_Types__c.  Class.SimilarConferencesController.: line 7, column 76 External entry point " when I try to launch my Visualforce page.

Here is my controller code:

 

public class SimilarConferencesController {

private final String conf_type;

public SimilarConferencesController() {
conf_type = [select id, name from Conference__c where id =
:ApexPages.currentPage().getParameters().get('id')].Technology_Types__c;


}



public ApexPages.StandardSetController setCon {
get {
if(setCon == null) {
setCon = new ApexPages.StandardSetController(Database.getQueryLocator([select id,name from Conference__c where Technology_Types__c = :conf_type]));
}
return setCon;
}
set;
}
public List<Conference__c> getSimilar() {
return (List<Conference__c>) setCon.getRecords();
}


}

 Here is the visualforce code just in case:

 

 

<apex:page controller="SimilarConferencesController" title="Conferences Like Me">

<apex:pageBlock title="Similar Conferences">
<apex:pageBlockTable value="{!similar}" var="a">
<apex:column value="{!a.name}"/>
</apex:pageBlockTable>

</apex:pageBlock>

</apex:page>

 

 

 

 I've followed the API's examples and I can't figure out what the actual problem is.  I found similar posts, but they didn't help me out very much.  Can anyone shed light on this?  I'm just trying to query the database to display Conference records whose technology type field match the source conference (its a custom link that triggers the visualforce page).

 

I feel like this is a mistake a lot of beginner's make (I'm on day 2 of APEX developement...).