Skip to content

Instantly share code, notes, and snippets.

@dancinllama
Created September 19, 2012 13:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dancinllama/3749781 to your computer and use it in GitHub Desktop.
Save dancinllama/3749781 to your computer and use it in GitHub Desktop.
java connection error handling examp
for (int i=0; i< saveResults.length; i++) {
if (saveResults[i].isSuccess()) {
System.out.println(i+". Successfully deleted record - Id: " + saveResults[i].getId());
} else {
Error[] errors = saveResults[i].getErrors();
for (int j=0; j< errors.length; j++) {
System.out.println("ERROR deleting record: " + errors[j].getMessage());
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment