The EBT card has one or both of food and cash sides (like having two different accounts on it). The food side is called SNAP and the cash side is called TANF. I will assure you that Wal-Mart did NOT return cash from the food side. The store manager really doesn't want to lose his job and the chain really doesn't want to lose the ability to accept benefits from the government. The terminal management software wouldn't let this happen and auditing systems would quickly pick it up if it somehow did. The sum of the food products must equal the charge.
On the other hand, why wouldn't the person be able to get cash from the cash side?