This report will show patients who have accessed the portal. The list is displayed based on patient and displays the patient name, parent name, patient number. If one parent has multiple children, the report will show the parent multiple times.
A sample image of this SQL report run in the Database Viewer is shown below:
- This will list a parent with 3 children 3 times.
- Add 'and (status_pat='ACTIVE')' to the SQL to show only active patients.
To highlight and copy the code below to your clipboard, simply click the Copy button.
select patno, fname, lname, first_name, last_name, email_addr from register inner join register_contact on register.patno = register_contact.patno inner join contact on contact.id = register_contact.contact_id left outer join web_user on web_user.contact_id = register_contact.contact_id where patno is not null and REGSTRTN_IND = 1