3

Consider the case where:

  • Address A has some BTC.
  • Address B is empty/zero.
  • Address C is the intended recipient.

B sending to C is invalid on its own, but does make sense if associated with A sending to B first

Can two dependent transactions be put into the same block and accepted?

  • A ==> B
  • B ==> C

(Since the net result will be OK, even though the second transaction does not make sense until the first one is completed)

6

Yes, but only if A -> B is placed before B -> C in the list of transactions.

Here is a graph of the percentage of transactions spending each other in the same block, it is usually around 10%.

3
  • So even within a block, there is a strict ordering of transactions? I had been under the impression that blocks were ordered, but transactions within a block were unordered! Very interesting. Thanks. – abelenky Jan 7 at 16:56
  • 1
    Actually, there are a substantial amount of such transactions :) Slightly related: eprint.iacr.org/2019/611 discusses those transactions as UTXOs created and spent in the same block reduce the size of the proofs – darosior Jan 7 at 17:02
  • 1
    @abelenky No, there is no strict ordering, at least for Bitcoin. The answer states one of the three requirements: 1) this answer 2) the coinbase tx comes first 3) no duplicate/invalid/double-spend transactions. There are usually multiple possible orderings satisfying these requirements. – MCCCS Jan 7 at 20:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.