+ Start a Discussion
AV NareshAV Naresh 

System.DmlException: Update failed. First exception on row 0; first error: MISSING_ARGUMENT, Id not specified in an update call: []

Hi,
I'm getting the below when i'm trying to update the record
System.DmlException: Update failed. First exception on row 0; first error: MISSING_ARGUMENT, Id not specified in an update call: []

Thanks in Advance

AT__c OOFRec =  new AT__c();
    public KB__c getOOFRec (){    
        List<AT__c> oofList = [select id, Details__c, Hide_Comments__c from KB__c where Context__c = 'IT Page' AND Title__c = 'Message2' limit 1];
        KB__c SupportOOF = new KB__c();
        if(oofList.size() > 0){ SupportOOF = oofList.get(0);
                   system.debug('tech supportOOF------'+techSupportOOF);}
        }
        return techSupportOOF;       
    }
    public void saveOOFRecord(){
            system.debug('tech supportOOF------'+OOFRecord);
            update OOFRecord;
    }
Best Answer chosen by AV Naresh
AV NareshAV Naresh
Hi guys,
Thanks for the response...
Got the result

Regards
Naresh

All Answers

Vishnu VaishnavVishnu Vaishnav
Hi Naresh,

You are updating "OOFRecord", error is coming bcoz u are not putting id in "OOFRecord" object.So check your code fill id in "OOFRecord".
Its only my suggestion , if u put your whole code may be i will go for better.

:::======================================================================:::
Qusetion Solved ? then mark as best answer to make helpful to others .....
Shaijan ThomasShaijan Thomas

OOFRecord - where you are declaring this list
Shaijan
AV NareshAV Naresh
Hi guys,
Thanks for the response...
Got the result

Regards
Naresh
This was selected as the best answer