My script needs to check for Customers with duplicate emails (more than 1 user that has the same email). Its quite a simple query but it involves access to the Customer table - in SQL
SELECT * FROM Customers WHERE email=$email;
(I have implemented using nlapiSearchRecord()).