Created
February 3, 2012 11:41
-
-
Save torarnv/1729796 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tracker-sparql -q "select ?u ?ta ?d ?ptc COUNT(?d) AS ?count { ?u a nmo:SMSMessage; tracker:added ?ta; nmo:sentDate ?d; nie:plainTextContent ?ptc } GROUP BY ?d ORDER BY ?count" | grep "[23456789]$" | while read row; do id=$(echo $row | cut -d " | |
," -f1 | cut -d ":" -f2); echo Deleting $id ...; tracker-sparql -qu "delete { <message:$id> a rdfs:Resource }"; done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
for safety, do 'tracker-control -b backup.db' first