Query fieldCondition for custom content type
Assuming you're using the Email field module, the column name is email, rather than value.

If that's the case, just change that line to:

-&gt;fieldCondition('field_email_address', 'email', $email_address, '=')


You may need to make a similar change for the password field, depending on what type it is. The easiest way to check for valid column names is in the .install file of the module that provides it, within its implementation of hook_field_schema().