Of all the things that could spill in a truck, dish soap is probably the best smelling, and easily cleaned, my wife had a jug of vegetable oil spill on the carpet at the rear hatchback in her Jeep Cherokee, I soaked it up with rags the best that I could, thankfully it does not have much of a smell, and the carpet was black so no stain appearance. We traded the Jeep shortly after for a new one so I don’t know if a smell would have developed with time. I now keep a rubberized bottom carpet in rear of her Jeep.
It would be worse if a jar of pickles, pickled fish or a can of paint was to spill in your vehicle.
The best thing to do is what someone else posted, carpet cleaner vacuum or shop vac.