Q: What is the journal entry for selling goods for no value (i.e. giving it away for free)?
A: Good question.
If the goods had value, let's say office furniture worth $300. And now you donate it to charity. Then you would:
Dr Donation (expense) $30 Cr Office furniture (asset) $30
If the goods had zero value, for example a machine that cost $1,000 and has been depreciated over 10 years to $0, and now you are giving it away for free, then you would simply cancel out the debit balance of the asset account ($1,000) by crediting it and cancel out the credit balance of the accumulated depreciation account ($1,000) by debiting it:
Dr Acc. Depr. (asset) $1,000 Cr Machine (asset) $1,000