included actual quarter for null cases
moved import function to shared folder