how to get the email address from auth_user table of requested user id in django 1.5?

Viewed 12352

I tried following line

appraiser_email = auth_user.objects.get(id__exact=2)

when i am executing above line it is saying

global name 'auth_user' is not defined

do i want to define a model auth_user in models.py or is there any other way?

thanks in advance

1 Answers
from django.contrib.auth.models import User

user = User.objects.get(id=2)
user_email = user.email
Related