• FlaCandian
  • NEWBIE
  • 0 Points
  • Member since 2008

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

I have a problem with partner api. I'm post part of the code.

 

 

try{
            String query="Select Id,Opportunity.Name,Opportunity.RecordTypeId,Opportunity.AN8__c,Opportunity.CloseDate,Codigo_Formula__c ,Quantity,UnitPrice,TotalPrice from OpportunityLineItem where OpportunityId in('006....')";
           
           
            qr = connSales.query(query);
            
            
            boolean bContinue = true;
            
            while (bContinue) {
               
                int loopI = 0;
                boolean loop = true;
                while(loop){
                    try{                   
                        for (int i = 0; i < qr.getRecords().length; i++) {
                            TreeMap valores = new TreeMap();
                            SObject con = qr.getRecords()[i]; in this point its work fine
                            SObject opp = (SObject)(con.get_any()[i].getObjectValue()); but this point not work

                                                Return null value.


                            ......


                         }

                     }catch(Exception e){

                    

                     }

                 }

          

 

The query returns the records but I can not recover the values of the parent object. Always returns null.