You need to sign in to do that
Don't have an account?
boliset kumar
Logging exceptions in custom object
Helo,
I am trying to log the exceptions in an custom object ,but after throwing an exception entire transaction is rolled back and i am not able to see in the custom objecy any help would be if great help for example
List<IBA_Store_Log__c> ibaLogs = New List<IBA_Store_Log__c>();
try {
integer x = 1/0;
} catch (exception e) {
IBA_Store_Log__c priceLog = IBA_store_datatableHelper.createIbaLog('ERROR', e.getmessage() + e.getlinenumber(), 'Iba_Store_Sap_Simulation', '');
ibalogs.add(priceLog);
throw e;
}finally {
IBA_store_datatableHelper.createIbaStoreLog(ibalogs);
}
I am trying to log the exceptions in an custom object ,but after throwing an exception entire transaction is rolled back and i am not able to see in the custom objecy any help would be if great help for example
List<IBA_Store_Log__c> ibaLogs = New List<IBA_Store_Log__c>();
try {
integer x = 1/0;
} catch (exception e) {
IBA_Store_Log__c priceLog = IBA_store_datatableHelper.createIbaLog('ERROR', e.getmessage() + e.getlinenumber(), 'Iba_Store_Sap_Simulation', '');
ibalogs.add(priceLog);
throw e;
}finally {
IBA_store_datatableHelper.createIbaStoreLog(ibalogs);
}
I do not see DML Insert statement anywhere in the code. Here I added