As noted in the comments, it's not the voltage you need to be thinking about, but rather the current. To see why, we must delve into some biology.
Your heart is kept beating by a network of nerves that rely on small bursts of electric current to communicate. Lethal electrocution happens when these nerves are interfered with by an external current, which usually leads to cardiac arrest. In order to interfere with nerve communication, the external current must be about as large as the current the nerves already use, which happens to be around a few mA. Hence, when receiving a shock with a current of a few mA, the muscles closest to the shock uncontrollably contract, which may lead to being unable to let go of whatever is shocking you.
Of course, your body has some electrical resistance, which means that for a longer path (like the one needed for current to flow through your heart), typically a bit more external current is required. This is why the figure of 10 mA for lethality is typically given. But this also requires another thing I've been assuming for a while: for electrocution to actually be lethal, it must be applied for at least a few seconds, or else the impulse will not significantly affect nerve functioning.
Now, back to your example. On a charged metal doorknob, the voltage between your hand and the doorknob is normally quite high. Additionally, when you receive the shock, though there is not much charge in motion, it moves extremely quickly, so the current can also be quite high (although it would take some impressive conditions indeed for it to be a significant fraction of an amp). But it only lasts for a few microseconds at most, meaning it fails to be anything more than uncomfortable.
In contrast, the shock from a power line actually does carry significant current, and it does so as long as you're holding onto the line. Since, as I've already mentioned, your muscles have contracted uncontrollably, that will probably be until you're dead.