With most children, threatening a spanking only cements in the focus to behave worse as a dare.
Child minds need the actual spanking to consider the errant behavior results in pain and highly negative connotations.
Can you believe it, I know many lovely children who never got spanked and grew up to adulthood and became perfect people?