OFAC scanning compares people named in financial activity with sanctioned parties, including the Specially Designated Nationals (SDN) list. Financial institutions can face significant penalties for doing business with sanctioned individuals, companies, countries, or assets. A basic dashboard scan provides a practical starting point; specialized third-party packages may be appropriate for more comprehensive screening. section 11.7
For ACH data, collect names from the relevant transaction records, normalize them by removing spaces, and compare them with SDN names and aliases. This can cover both PPD transactions and international ACH transactions (IAT). Selecting distinct names reduces repeated work across batches, while retaining file and batch identifiers makes a possible match traceable to its source. section 11.7.2
A basic matching workflow can be built step by step:
- Load individual names from ACH transaction records and names plus aliases from the SDN list. section 11.7.2
- Install PostgreSQL fuzzystrmatch to use phonetic algorithms and Levenshtein distance rather than relying only on exact or wildcard searches. section 11.7.2
- Calculate a similarity score for cleaned names and test phonetic matches against both SDN names and aliases. section 11.7.2
- Combine PPD and IAT results, then flag records meeting a similarity threshold or a phonetic-match condition. section 11.7.2
Listing 11.30 Filtering the results
SELECT ROW_NUMBER() #1
OVER (ORDER BY ach_files_id, ach_batch_id) AS id, * #1
FROM computed_similarity #1
WHERE similarity_score >= 80 #2
OR daitch_mokotoff_match_name = TRUE #2
OR daitch_mokotoff_match_alias = TRUE #2
ORDER BY similarity_score DESC
This query shows the final review filter: it retains records with an 80-or-higher similarity score or a phonetic match, then orders likely matches first. section 11.7.2
A match is a result for review, not merely a name to display. Return the file, batch, SDN name, transaction name, alias, similarity score, and phonetic-match flags so users can inspect why a record was flagged. A typed API response and a MUI DataGrid can present those results with links back to the associated file and batch. section 11.9.2
Listing 11.38 The OfacRecords component
interface OfacRecordsProps {
records: OfacResponse[];
}
export default function OfacRecords({records}:
➥Readonly<OfacRecordsProps>) {
const columns: GridColDef[] = [
{
field: 'ach_files_id', #1
headerName: '', #1
width: 100, #1
renderCell: (params) => ( #1
<Link href={`/fileDetails/${params.value}`} #1
color="inherit"> #1
View File #1
</Link> #1
), #1
}, #1
{
field: 'ach_batch_id', #2
headerName: '', #2
width: 100, #2
renderCell: (params) => ( #2
<Link #2
href={`/fileDetails #2
/${params.row.ach_files_id}/batchDetails #2
/${params.value}`} #2
color="inherit"> #2
View batch #2
</Link> #2
), #2
}, #2
…
{field: 'similarity_score', #3
headerName: 'Score', width: 75, #3
renderCell: (params) => ( #3
<Typography>{Math.floor(params.value)}</Typography> #3
)}, #3
{ #4
field: 'daitch_mokotoff_match_name', #4
headerName: 'Name Match', #4
width: 100, #4
renderCell: (params) => ( #5
… #5
{params.value ? #5
<CheckCircle sx={{color: "green"}}/> : null} #5
… #5
},
{
field: 'daitch_mokotoff_match_alias', #6
headerName: 'Alias Match', #6
width: 100, #6
renderCell: (params) => ( #6
… #6
{params.value ? #6
<CheckCircle sx={{color: "green"}}/> : null} #6
… #6
}, #6
]; #6
…
<DataGrid columns={columns} rows={records}/> #7
…
The results component illustrates a review-oriented grid: each row exposes OFAC match data and links investigators to the originating ACH file or batch. section 11.9.2
From page-load scan to retained evidence
Scanning every loaded file whenever a user opens a report may work with limited data, but it repeats work for every view. With an SDN list of more than 15,000 records and high ACH volume, dynamic scanning can slow the application. It also leaves no historical record: list changes can make a prior result impossible to reproduce. A production-oriented design scans when a file is loaded and periodically scans stored data, then preserves results for review and archival retrieval. section 11.9.3
