# Patrons with Blocking Notes

**URL:** https://forum.innovativeusers.org/t/patrons-with-blocking-notes/1240
**Category:** Polaris Repository
**Tags:** polaris-patrons, cp-migration
**Created:** [June 2, 2023, 9:05pm UTC](https://forum.innovativeusers.org/t/patrons-with-blocking-notes/1240 "2023-06-02T21:05:25Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![system](https://forum.innovativeusers.org/uploads/db7787/original/2X/8/8519ee8eef6492f310ea87d4ce482d931f01eef2.png) [@system](https://forum.innovativeusers.org/u/system)
#### Post date: [June 2, 2023, 9:05pm UTC](https://forum.innovativeusers.org/t/patrons-with-blocking-notes/1240/1 "2023-06-02T21:05:25Z")

</div>

# Patrons with Blocking Notes

Pull a list of patrons with blocking notes. Gives you the patron ID, barcode, name, note text, and last updated date.

```SQL
SELECT
    pn.PatronID AS "Patron ID",
    p.Barcode AS "Barcode",
    pr.PatronFullName AS "Name",
    pn.BlockingStatusNotes as "Notes",
    pn.BlockingStatusNoteDate AS "Last Noted"

FROM
    Polaris.Polaris.PatronNotes pn WITH (NOLOCK)

INNER JOIN
    Polaris.Polaris.Patrons p WITH (NOLOCK) ON p.PatronID = pn.PatronID
INNER JOIN
    Polaris.Polaris.PatronRegistration pr WITH (NOLOCK) ON pr.PatronID = pn.PatronID

WHERE
    DATALENGTH(pn.BlockingStatusNotes) > 0
ORDER BY
    pn.NonBlockingStatusNoteDate DESC

```
