Skip to content

Commit

Permalink
Merge pull request #64 from ministryofjustice/fix-formatting-issues
Browse files Browse the repository at this point in the history
fixing formatting issues
  • Loading branch information
kth13 authored Aug 2, 2024
2 parents 1347da7 + 1f2c43d commit 0591dfa
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions source/runbooks/delete-stale-draft-referrals.html.md.erb
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,10 @@ review_in: 1 year

# Deleting stale draft referrals


```

### sample command for cascade deleting draft referrals based on a condition

```

delete from referral_service_user_data where referral_id in (select dr.id from draft_referral dr
left outer join referral r on dr.id = r.id
where r.id is null and dr.created_at <= CURRENT_DATE - INTERVAL '90 days')
Expand All @@ -37,5 +35,7 @@ delete from draft_referral where id in (select dr.id from draft_referral dr
left outer join referral r on dr.id = r.id
where r.id is null and dr.created_at <= CURRENT_DATE - INTERVAL '90 days')

```



0 comments on commit 0591dfa

Please sign in to comment.