The error you are getting is a MySQL error, it is coming from your db, not the validation toolkit. It looks like this could be coming from the 'Check new Username' server behavior.
What is the data type of the UserCompanyID column in your table? Give the following a try to see if it allows you to get past this issue.
Update line 38 from this:
$LoginRS__query = "SELECT UserCompanyID FROM users WHERE UserCompanyID='" . $loginUsername . "'";
to this:
$LoginRS__query = "SELECT UserCompanyID FROM users WHERE UserCompanyID=`" . $loginUsername . "`";
Post back and let us know how this works and any other details about your setup if you are still having problems.