You are here

function _user_import_existing_uid in User Import 8

Same name and namespace in other branches
  1. 5.2 user_import.module \_user_import_existing_uid()
  2. 5 supported/user.inc \_user_import_existing_uid()
  3. 6.4 supported/user.inc \_user_import_existing_uid()
  4. 6.2 supported/user.inc \_user_import_existing_uid()
  5. 7.3 supported/user.inc \_user_import_existing_uid()
  6. 7 supported/user.inc \_user_import_existing_uid()
  7. 7.2 supported/user.inc \_user_import_existing_uid()

Return an existing user ID, if present, for a given email.

1 call to _user_import_existing_uid()
_user_import_validate_email in supported/user.inc

File

supported/user.inc, line 328

Code

function _user_import_existing_uid($email) {
  $sql = 'SELECT uid FROM {users} WHERE mail = :mail';
  $args = array(
    ':mail' => $email,
  );
  $uid = db_query_range($sql, 0, 1, $args)
    ->fetchField();
  return $uid;
}