Added reading records by external ID; fixed some XML coding issues.