Find the transaction you want to get rid of:
listunspent
Note the "address" (for later), "txid" and "vout" lines.
createrawtransaction \
'[{"txid": "THE_TXID", "vout": VOUT}]' \
'[{ "tb1qryakg74re8an5yc99nsznj4f7t94rghk6m986l": 0}]'
Note the result as RAWTX. The address used in this raw transaction is not important. 0 is sent to it. All goes to mining fees. But it has to be a valid address.
Now get the private key for the "address":
dumpprivkey "address"
Note the result as PRIVKEY.
signrawtransactionwithkey RAWTX '["PRIVKEY"]'
Note the "hex" result as SIGNEDRAWTX and send it:
sendrawtransaction SIGNEDRAWTX
Can also be found at bin.bublina.eu.org or even via Tor at the onion address.