No Peer Assigned Referrals (NoPAR) (PDF)

Report Overview
•••
No Peer Assigned
Referrals (NoPAR)
This report has four tabs. The first tab is a
reference report that can be used to obtain
the Organization ID(s) necessary to identify
the agency referrals to include in the report.
The second tab is a list of clients referred
during the specified time period for the
specified agency. The third tab is a list of
those from Tab 2 who have been assigned a
peer. The fourth tab lists those from Tab 2
who have not been assigned a peer. The
Infoview Report Template Guidance –
BREASTFEEDING – PEER PROGRAM
Notes
* This report provides private information. Please
refer to the MN WIC Data Privacy Policy (Ref:
MOM, Section 1.7).
main purpose of this report is to make sure
* The report lists clients who were referred after peer
that all clients referred are assigned a peer.
assignment: This report looks for peer assignments
Tab 1 – Organization IDs: List of
Organization IDs whose descriptions
include the word “peer”.
Tab 2 – referral list: List of clients referred
during the specified time period.
Tab 3 – Refs with peer assigned: List of
clients from the referral list who have been
assigned a peer.
Tab 4 – no peer assigned: List of clients
from the referral list who have not been
assigned a peer.
who had already been assigned a peer prior to the
made during or after the specified time period. Clients
specified time period who were re-referred during the
time period may appear in Tab 4 on the no peer
assigned list.
* Infants referrals are included in the referral list but
in the no peer assigned tab the mother, not the infant, is
listed.
* The Due/Deliv date returns the Expected delivery
date but replaces it with the Actual delivery date once
the Actual delivery date is known.
* The Agencyid and Servicesiteid are the agency and clinic the participant currently belongs to, not
the agency/clinic where the contact was made.
* TheWIC status is the participant’s current WIC Type and may not reflect the participant’s WIC
Type at the time the contact was made.
Tab 1 – Organization IDs
1|Page
MN Department of Health WIC Program
Peer Active Client List
•••
Tab 2 – referral list
Tab 3 – Refs with peer assigned
Tab 4 – no peer assigned
2|Page
Peer Active Client List
•••
Prompt
Static Criteria
referrals Query
REFERRALCONTACTITEM.REFERRALDATE BETWEEN <Referral Start Date> AND <Referral
End Date> AND
MEMBER.WICSTATUS IN ( 'B','P','N' )
Explanation: Include records within these dates where participants are women
Peer assigned Query
BFCOUNSELORCONTACT.STATEWICID IN <list from referrals query> AND
BFCOUNSELORCONTACTTOPIC.BFCONTACTTOPICID IN (null, 1, 5, 47, 48, 49, 53 ) AND
BFCOUNSELORCONTACT.CONTACTDATE > <Referral Start Date>
Explanation: Only include participants identified by the referrals query who have a contact since the
Referral Start Date that is of type “date peer assigned” or “date changed peer” or “date peer services
began”
No peer assigned Query
BFCOUNSELORCONTACT.STATEWICID IN <list from referrals query>
EXCEPT
BFCOUNSELORCONTACT.STATEWICID IN <list from Peer assigned query>
Explanation: Only include participants identified by the referrals query who are not on the list of
referrals with a peer assigned
Tab 1 – Organization IDs
Columns
•
Organizationid (ORGANIZATION.ORGANIZATIONID)
•
Name (ORGANIZATION.NAME)
3|Page
Peer Active Client List
•••
Sorted by
•
Statewicid (Ascending Alphabetical)
Tab 2 – referral list
Columns
•
Statewicid (REFERRALCONTACTITEM.StateWICID)
•
Householdid (MEMBER.HouseholdID)
•
Wicstatus (MEMBER.WICStatus)
•
Referraldate (REFERRALCONTACTITEM.Referraldate)
•
Organizationid (REFERRALCONTACTITEM.Organizationid)
•
Createuserid (REFERRALCONTACTITEM.Createuserid)
Sorted by
•
Statewicid (Ascending Alphabetical)
Tab 3 – Refs with peer assigned
Columns
•
Statewicid (BFCOUNSELORCONTACT.StateWICID)
•
Householdid (MEMBER.HouseholdID)
•
WIC status (MEMBER.WICStatus)
•
date peer assigned (BFCOUNSELORCONTACT.Contactdate)
Sorted by
•
Statewicid (Ascending Alphabetical)
Tab 4 – no peer assigned
Columns
•
Referral Date (see Referral Date under Variables)
•
Householdid (MEMBER.HouseholdID)
•
Agency ID (MEMBER.Agencyid)
•
Service Site ID (MEMBER.ServiceSiteid)
•
Last Name (MEMBER.Lastname)
•
Dateofbirth (MEMBER.Dateofbirth)
4|Page
Peer Active Client List
•••
•
Due/Deliv date (see Delivorduedate under Variables)
•
Createuserid (see Createuserid under Variables)
Sorted by
•
Agency ID (MEMBER.Agencyid)
•
Referral Date (see Referral Date under Variables)
Technical Notes
Notes
This report lists referrals made and then divides that list into those with a peer assigned and those without a
peer assigned. The main purpose of the report is to make sure that all clients referred are assigned to a peer.
Variables
Delivorduedate =If(IsNull(Max([Expdelivdate]))) Then Max([Actdelivdate]) Else Max([Expdelivdate])
Referral Date =Min([no peer assigned].[Referraldate])
Createuserid =[no peer assigned].[Createuserid]
Statewicid=[no peer assigned].[Statewicid]
SQL (no changes to generated code)
Referrals Query
SELECT
dbo.MEMBER.HOUSEHOLDID,
dbo.REFERRALCONTACTITEM.STATEWICID,
dbo.MEMBER.WICSTATUS,
dbo.REFERRALCONTACTITEM.ORGANIZATIONID,
dbo.REFERRALCONTACTITEM.REFERRALDATE,
dbo.REFERRALCONTACTITEM.CREATEUSERID
FROM
dbo.MEMBER INNER JOIN dbo.REFERRALCONTACTITEM ON
(dbo.MEMBER.STATEWICID=dbo.REFERRALCONTACTITEM.STATEWICID)
WHERE
( dbo.REFERRALCONTACTITEM.REFERRALDATE BETWEEN '03/01/2015 00:0:0' AND '07/31/2015 00:0:0'
AND dbo.REFERRALCONTACTITEM.ORGANIZATIONID IN (5664, 5846)
Org table Query
SELECT
dbo.ORGANIZATION.ORGANIZATIONID,
5|Page
Peer Active Client List
•••
dbo.ORGANIZATION.NAME
FROM
dbo.ORGANIZATION
WHERE
dbo.ORGANIZATION.NAME LIKE '%peer%'
Peer assigned Query
SELECT
dbo.MEMBER.HOUSEHOLDID,
dbo.BFCOUNSELORCONTACT.STATEWICID,
dbo.MEMBER.WICSTATUS,
dbo.BFCOUNSELORCONTACT.CONTACTDATE,
dbo.BFCOUNSELORCONTACT.BFCOUNSELORID,
dbo.BFCOUNSELORCONTACT.BFCOUNSELORCONTACTID,
dbo.BFCOUNSELORCONTACTTOPIC.BFCONTACTTOPICID,
dbo.REFERRALCONTACTITEM.REFERRALDATE
FROM
dbo.REFERRALCONTACTITEM INNER JOIN dbo.MEMBER ON
(dbo.MEMBER.STATEWICID=dbo.REFERRALCONTACTITEM.STATEWICID)
INNER JOIN dbo.BFCOUNSELORCONTACT ON
(dbo.MEMBER.STATEWICID=dbo.BFCOUNSELORCONTACT.STATEWICID)
INNER JOIN dbo.BFCOUNSELORCONTACTTOPIC ON
(dbo.BFCOUNSELORCONTACT.BFCOUNSELORCONTACTID=dbo.BFCOUNSELORCONTACTTOPIC.BFCO
UNSELORCONTACTID)
WHERE
( dbo.BFCOUNSELORCONTACT.STATEWICID IN (<results from referrals>)
AND ( dbo.BFCOUNSELORCONTACTTOPIC.BFCONTACTTOPICID IN ( 1, 5, 47, 48, 49, 53 ) OR
dbo.BFCOUNSELORCONTACTTOPIC.BFCONTACTTOPICID Is Null)
AND dbo.BFCOUNSELORCONTACT.CONTACTDATE > '03/02/2015 00:0:0' )
no peer assigned Query
SELECT
dbo.MEMBER.STATEWICID,
dbo.MEMBER.HOUSEHOLDID,
dbo.MEMBER.AGENCYID,
dbo.MEMBER.SERVICESITEID,
dbo.MEMBER.LASTNAME,
dbo.MEMBER.DATEOFBIRTH,
dbo.POSTPARTUM.ACTDELIVDATE,
dbo.PREGNANCY.EXPDELIVDATE,
dbo.REFERRALCONTACT.REFERRALDATE,
dbo.REFERRALCONTACT.CREATEUSERID
FROM
dbo.PREGNANCY INNER JOIN dbo.CERTCONTACT ON
(dbo.PREGNANCY.PREGNANCYID=dbo.CERTCONTACT.PREGNANCYID)
6|Page
Peer Active Client List
•••
INNER JOIN dbo.MEMBER ON (dbo.CERTCONTACT.CERTIFICATIONID=dbo.MEMBER.CERTIFICATIONID)
INNER JOIN dbo.REFERRALCONTACTITEM ON
(dbo.MEMBER.STATEWICID=dbo.REFERRALCONTACTITEM.STATEWICID)
INNER JOIN dbo.REFERRALCONTACT ON
(dbo.REFERRALCONTACTITEM.STATEWICID=dbo.REFERRALCONTACT.STATEWICID)
full outer JOIN dbo.POSTPARTUM ON (dbo.MEMBER.STATEWICID=dbo.POSTPARTUM.STATEWICID)
WHERE
(dbo.MEMBER.STATEWICID IN @dpvalue('A', DP0.DO2db) AND
dbo.REFERRALCONTACT.REFERRALDATE IN @dpvalue('D', DP0.DO2dc)
AND dbo.MEMBER.WICSTATUS IN ( 'B','P','N' ))
EXCEPT
SELECT
dbo.MEMBER.STATEWICID,
dbo.MEMBER.HOUSEHOLDID,
dbo.MEMBER.AGENCYID,
dbo.MEMBER.SERVICESITEID,
dbo.MEMBER.LASTNAME,
dbo.MEMBER.DATEOFBIRTH,
dbo.POSTPARTUM.ACTDELIVDATE,
dbo.PREGNANCY.EXPDELIVDATE,
dbo.REFERRALCONTACT.REFERRALDATE,
dbo.REFERRALCONTACT.CREATEUSERID
FROM
dbo.PREGNANCY INNER JOIN dbo.CERTCONTACT ON
(dbo.PREGNANCY.PREGNANCYID=dbo.CERTCONTACT.PREGNANCYID)
INNER JOIN dbo.MEMBER ON (dbo.CERTCONTACT.CERTIFICATIONID=dbo.MEMBER.CERTIFICATIONID)
INNER JOIN dbo.REFERRALCONTACTITEM ON
(dbo.MEMBER.STATEWICID=dbo.REFERRALCONTACTITEM.STATEWICID)
INNER JOIN dbo.REFERRALCONTACT ON
(dbo.REFERRALCONTACTITEM.STATEWICID=dbo.REFERRALCONTACT.STATEWICID)
full outer JOIN dbo.POSTPARTUM ON (dbo.MEMBER.STATEWICID=dbo.POSTPARTUM.STATEWICID)
WHERE
(dbo.MEMBER.STATEWICID IN @dpvalue('A', DP2.DO390)
AND dbo.REFERRALCONTACT.REFERRALDATE IN @dpvalue('D', DP0.DO2dc)
AND dbo.MEMBER.WICSTATUS IN ( 'B','P','N' ))
7|Page