We are currently updating the OP Help Center content for the release of OP 14.19 or OP 19. OP 19 is a member of the certified OP 14 family of products (official version is 14.19.1), which you may see in your software (such as in Help > About) and in the Help Center tabs labeled 14.19. You may also notice that the version number in content and videos may not match the version of your software, and some procedural content may not match the workflow in your software. We appreciate your patience and understanding as we make these enhancements.

SQL: Nurse Vaccine Productivity


This SQL is intended to indicate who the vaccinator was for all the shots given in your office during a selected date range.

A sample image of this SQL report run in the Database Viewer is shown below:


"Vaccinator" is defined as the staff member that appears in the S_ADDR_ID.  Most practices use this as "who actually poked the kid.”  If your practice enters “ordering doc” here instead, you’ll receive different results.

"Number of kids who got vaccinated" is different than  "number of separate sticks" because Bertha might give 4 flu shots, one to each of 4 kids, and Wanda might give 4 vaccines to 1 baby.


To highlight and copy the code below to your clipboard, simply click the Copy button.

select  date_given,count(patno) as kids, sum(shots) as sticks, vaccinator from

select patno, date_given, count(vaccine) as shots, vaccinator from
select patno, vacdate as date_given,vacname as vaccine,  staff2.staffname as vaccinator
from vaccine1
inner join staff1 staff2 on staff2.staffid = vaccine1.s_addr_id
inner join vac_inventory on vac_inventory.uniqkey = vaccine1.vac_lot_id
where vacdate between :start_date and :end_date and vaccine1.vfc1 <> 9
group by patno, date_given, vaccinator
order by date_given
) group by date_given, vaccinator