add ability to get profile from queries