Subject Average age
Author Andrea Raimondi

I have a field called DOB( DateOfBirth ) in one of my tables.
I need to gather average age for males/females artenatively.

My SQL is like this now:

Select avg( ( extract( year from ???? ) - extract(year from DOB) ) /
count( * ) )from TblPerson where( Sex = 'Female' )

I don't remember how the function to retrieve actual date is called.
Plus, if you see any other wrong thing with this query, please do
point me to what's wrong and how to fix it.