My take on this is that the scriptwriter's goal was not to stop SQL injection attacks but rather prevent regular users from inadvertently screwing with the database.
Looking at it that way makes it a much more understandable (and all-too-common, unfortunately) oversight.