There is a halakhic principle that one is not punished twice for performing a single act, even if two people were harmed by that transgression. However, if one transgression preceded the other even slightly, he may be punished for both actions. Once the liability for the first transgression is established, it remains intact. Nevertheless, when one is liable to receive both lashes and capital punishment, he is executed and not flogged due to the principle that one receives the greater of the two punishments. However, fundamentally, liability to receive the first punishment remains. Indeed, in a case where one is liable to be flogged and to pay restitution, he is required to pay the restitution if, for some reason, the lashes cannot be administered.
This is relevant to the laws of Shabbat in a case where the violation of Shabbat happens at the same time that a theft is committed. The Gemara on today’s daf quotes a baraita:
One who steals a purse on Shabbat is liable for the theft. Based on the principle that one who is liable to receive two punishments receives the greater of the two, in this case one should be exempt from payment for the theft, since performing a prohibited labor on Shabbat is punishable by stoning. However, this case is different because he was already liable for theft as soon as he lifted the purse. This took place before he came to violate the prohibition of performing prohibited labor on Shabbat by carrying it into the public domain. However, if he did not lift the purse, but was dragging it on the ground and exiting the private domain, he is exempt from paying for the theft , as in that case, he is only liable for the theft when he drags the purse out of the owner’s property into the public domain. The prohibition of theft and the prohibition of Shabbat are violated all at once.
For one to be liable for theft, two criteria must be met. First, the thief must intend to take an object that belonged to another for himself. Second, he must transfer the object into his possession by means of a valid transaction. Only by means of acquiring the object does he perform the transgression. This acquisition can be accomplished by means of lifting the object or, alternatively, by taking it out of the owner’s property without lifting it.