will DB_TRX_ID hidden field modified smaller than it use be?Can I concatenate multiple MySQL rows into one field?Why is this a deadlock (MySQL using InnoDB)Does the order of fields in a WHERE clause affect performance in MySQL?MySQL 'select for update' behaviourReference - What does this error mean in PHP?ORDER BY “ENUM field” with an calculated field in MYSQLDoes locking a row in MySQL/InnoDB always lock all associated index records as well?MySQL InnoDB deadlock between select for update and insertMySQL lock and statements that lock rows using a unique indexHigh level algorithm that MySQL MVCC uses to build the previous snapshot

貧しい【まずしい】 poor 貧乏【びんぼう】な poor What's the difference?

Does Disney no longer produce hand-drawn cartoon films?

Why didn't Voldemort recognize that Dumbledore was affected by his curse?

Longest bridge/tunnel that can be cycled over/through?

Electricity free spaceship

Skin Effect of resistors

English word for "product of tinkering"

What is the color of artificial intelligence?

How come the nude protesters were not arrested?

US doctor working in Tripoli wants me to open online account

Who are the Missing Members of this Noble Family?

If every company in the economy earns zero economic profit, can they contribute to real economic growth?

Fixing obscure 8080 emulator bug?

Why does Sin[b-a] simplify to -Sin[a-b]?

What is the actual quality of machine translations?

Are there any important biographies of nobodies?

Let M and N be single-digit integers. If the product 2M5 x 13N is divisible by 36, how many ordered pairs (M,N) are possible?

How can I end combat quickly when the outcome is inevitable?

Determining fair price for profitable mobile app business

Can I utilise a baking stone to make crepes?

Does the Long March-11 increase its thrust after clearing the launch tower?

Winning Strategy for the Magician and his Apprentice

Is White controlling this game?

How can I get an unreasonable manager to approve time off?



will DB_TRX_ID hidden field modified smaller than it use be?


Can I concatenate multiple MySQL rows into one field?Why is this a deadlock (MySQL using InnoDB)Does the order of fields in a WHERE clause affect performance in MySQL?MySQL 'select for update' behaviourReference - What does this error mean in PHP?ORDER BY “ENUM field” with an calculated field in MYSQLDoes locking a row in MySQL/InnoDB always lock all associated index records as well?MySQL InnoDB deadlock between select for update and insertMySQL lock and statements that lock rows using a unique indexHigh level algorithm that MySQL MVCC uses to build the previous snapshot






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;








1















according to mysql reference, 6-byte transaction ID field will be added in the cluster index record and will be set to the value the transaction which create/modifed it.
my question is:
let say transaction 1, 2 are active in mysql and 2 modified a record, meanwhile set its transaction ID to 2. release the lock and exit. then transaction 1 entered in and modified the same record again, will transaction ID be modified smaller than 2 to 1?










share|improve this question






























    1















    according to mysql reference, 6-byte transaction ID field will be added in the cluster index record and will be set to the value the transaction which create/modifed it.
    my question is:
    let say transaction 1, 2 are active in mysql and 2 modified a record, meanwhile set its transaction ID to 2. release the lock and exit. then transaction 1 entered in and modified the same record again, will transaction ID be modified smaller than 2 to 1?










    share|improve this question


























      1












      1








      1








      according to mysql reference, 6-byte transaction ID field will be added in the cluster index record and will be set to the value the transaction which create/modifed it.
      my question is:
      let say transaction 1, 2 are active in mysql and 2 modified a record, meanwhile set its transaction ID to 2. release the lock and exit. then transaction 1 entered in and modified the same record again, will transaction ID be modified smaller than 2 to 1?










      share|improve this question
















      according to mysql reference, 6-byte transaction ID field will be added in the cluster index record and will be set to the value the transaction which create/modifed it.
      my question is:
      let say transaction 1, 2 are active in mysql and 2 modified a record, meanwhile set its transaction ID to 2. release the lock and exit. then transaction 1 entered in and modified the same record again, will transaction ID be modified smaller than 2 to 1?







      mysql innodb






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Mar 24 at 22:04







      Keyang Ma

















      asked Mar 24 at 18:54









      Keyang MaKeyang Ma

      186




      186






















          1 Answer
          1






          active

          oldest

          votes


















          0














          If you're interested in InnoDB internal storage formats, you might like to get Jeremy Cole's Innodb_ruby tool.



          I tried creating a table test.foo with 1 row, and updated the row with a series of transactions. I can then use Jeremy Cole's script to dump the page:



          innodb_space -s ibdata1 -T test/foo -p 3 page-dump

          ...

          records:
          :format=>:compact,
          :offset=>125,
          :header=>
          :next=>112,
          :type=>:conventional,
          :heap_number=>2,
          :n_owned=>0,
          :min_rec=>false,
          :deleted=>false,
          :nulls=>[],
          :lengths=>,
          :externs=>[],
          :length=>5,
          :next=>112,
          :type=>:clustered,
          :key=>[:name=>"id", :type=>"BIGINT UNSIGNED", :value=>7],
          :row=>[],
          :sys=>
          [:name=>"DB_TRX_ID", :type=>"TRX_ID", :value=>2843,
          :name=>"DB_ROLL_PTR",
          :type=>"ROLL_PTR",
          :value=>
          :is_insert=>true, :rseg_id=>20, :undo_log=>:page=>335, :offset=>272],
          :length=>21,
          :transaction_id=>2843,
          :roll_pointer=>
          :is_insert=>true, :rseg_id=>20, :undo_log=>:page=>335, :offset=>272


          You can see under the :sys key there's the DB_TRX_ID. As I make further updates to the row, this value is changed. You can try it yourself and see how the value changes.



          Read Jeremy's series of blog posts to understand more about the InnoDB format:



          Here's a list of his blog posts: https://blog.jcole.us/innodb/






          share|improve this answer























          • My pleasure. Remember it is traditional on Stack Overflow to upvote an answer that helps you, or mark as "accepted" the answer that really answers your question fully. See stackoverflow.com/help/someone-answers

            – Bill Karwin
            Mar 25 at 12:23






          • 1





            my bad. I first vote the answer and it turns out that I'm the new comer for the stack overflow and my vote can't be used to influence the rank. so I just give up other actions like accepted the answer.

            – Keyang Ma
            Mar 25 at 20:46











          Your Answer






          StackExchange.ifUsing("editor", function ()
          StackExchange.using("externalEditor", function ()
          StackExchange.using("snippets", function ()
          StackExchange.snippets.init();
          );
          );
          , "code-snippets");

          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "1"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55327342%2fwill-db-trx-id-hidden-field-modified-smaller-than-it-use-be%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          0














          If you're interested in InnoDB internal storage formats, you might like to get Jeremy Cole's Innodb_ruby tool.



          I tried creating a table test.foo with 1 row, and updated the row with a series of transactions. I can then use Jeremy Cole's script to dump the page:



          innodb_space -s ibdata1 -T test/foo -p 3 page-dump

          ...

          records:
          :format=>:compact,
          :offset=>125,
          :header=>
          :next=>112,
          :type=>:conventional,
          :heap_number=>2,
          :n_owned=>0,
          :min_rec=>false,
          :deleted=>false,
          :nulls=>[],
          :lengths=>,
          :externs=>[],
          :length=>5,
          :next=>112,
          :type=>:clustered,
          :key=>[:name=>"id", :type=>"BIGINT UNSIGNED", :value=>7],
          :row=>[],
          :sys=>
          [:name=>"DB_TRX_ID", :type=>"TRX_ID", :value=>2843,
          :name=>"DB_ROLL_PTR",
          :type=>"ROLL_PTR",
          :value=>
          :is_insert=>true, :rseg_id=>20, :undo_log=>:page=>335, :offset=>272],
          :length=>21,
          :transaction_id=>2843,
          :roll_pointer=>
          :is_insert=>true, :rseg_id=>20, :undo_log=>:page=>335, :offset=>272


          You can see under the :sys key there's the DB_TRX_ID. As I make further updates to the row, this value is changed. You can try it yourself and see how the value changes.



          Read Jeremy's series of blog posts to understand more about the InnoDB format:



          Here's a list of his blog posts: https://blog.jcole.us/innodb/






          share|improve this answer























          • My pleasure. Remember it is traditional on Stack Overflow to upvote an answer that helps you, or mark as "accepted" the answer that really answers your question fully. See stackoverflow.com/help/someone-answers

            – Bill Karwin
            Mar 25 at 12:23






          • 1





            my bad. I first vote the answer and it turns out that I'm the new comer for the stack overflow and my vote can't be used to influence the rank. so I just give up other actions like accepted the answer.

            – Keyang Ma
            Mar 25 at 20:46















          0














          If you're interested in InnoDB internal storage formats, you might like to get Jeremy Cole's Innodb_ruby tool.



          I tried creating a table test.foo with 1 row, and updated the row with a series of transactions. I can then use Jeremy Cole's script to dump the page:



          innodb_space -s ibdata1 -T test/foo -p 3 page-dump

          ...

          records:
          :format=>:compact,
          :offset=>125,
          :header=>
          :next=>112,
          :type=>:conventional,
          :heap_number=>2,
          :n_owned=>0,
          :min_rec=>false,
          :deleted=>false,
          :nulls=>[],
          :lengths=>,
          :externs=>[],
          :length=>5,
          :next=>112,
          :type=>:clustered,
          :key=>[:name=>"id", :type=>"BIGINT UNSIGNED", :value=>7],
          :row=>[],
          :sys=>
          [:name=>"DB_TRX_ID", :type=>"TRX_ID", :value=>2843,
          :name=>"DB_ROLL_PTR",
          :type=>"ROLL_PTR",
          :value=>
          :is_insert=>true, :rseg_id=>20, :undo_log=>:page=>335, :offset=>272],
          :length=>21,
          :transaction_id=>2843,
          :roll_pointer=>
          :is_insert=>true, :rseg_id=>20, :undo_log=>:page=>335, :offset=>272


          You can see under the :sys key there's the DB_TRX_ID. As I make further updates to the row, this value is changed. You can try it yourself and see how the value changes.



          Read Jeremy's series of blog posts to understand more about the InnoDB format:



          Here's a list of his blog posts: https://blog.jcole.us/innodb/






          share|improve this answer























          • My pleasure. Remember it is traditional on Stack Overflow to upvote an answer that helps you, or mark as "accepted" the answer that really answers your question fully. See stackoverflow.com/help/someone-answers

            – Bill Karwin
            Mar 25 at 12:23






          • 1





            my bad. I first vote the answer and it turns out that I'm the new comer for the stack overflow and my vote can't be used to influence the rank. so I just give up other actions like accepted the answer.

            – Keyang Ma
            Mar 25 at 20:46













          0












          0








          0







          If you're interested in InnoDB internal storage formats, you might like to get Jeremy Cole's Innodb_ruby tool.



          I tried creating a table test.foo with 1 row, and updated the row with a series of transactions. I can then use Jeremy Cole's script to dump the page:



          innodb_space -s ibdata1 -T test/foo -p 3 page-dump

          ...

          records:
          :format=>:compact,
          :offset=>125,
          :header=>
          :next=>112,
          :type=>:conventional,
          :heap_number=>2,
          :n_owned=>0,
          :min_rec=>false,
          :deleted=>false,
          :nulls=>[],
          :lengths=>,
          :externs=>[],
          :length=>5,
          :next=>112,
          :type=>:clustered,
          :key=>[:name=>"id", :type=>"BIGINT UNSIGNED", :value=>7],
          :row=>[],
          :sys=>
          [:name=>"DB_TRX_ID", :type=>"TRX_ID", :value=>2843,
          :name=>"DB_ROLL_PTR",
          :type=>"ROLL_PTR",
          :value=>
          :is_insert=>true, :rseg_id=>20, :undo_log=>:page=>335, :offset=>272],
          :length=>21,
          :transaction_id=>2843,
          :roll_pointer=>
          :is_insert=>true, :rseg_id=>20, :undo_log=>:page=>335, :offset=>272


          You can see under the :sys key there's the DB_TRX_ID. As I make further updates to the row, this value is changed. You can try it yourself and see how the value changes.



          Read Jeremy's series of blog posts to understand more about the InnoDB format:



          Here's a list of his blog posts: https://blog.jcole.us/innodb/






          share|improve this answer













          If you're interested in InnoDB internal storage formats, you might like to get Jeremy Cole's Innodb_ruby tool.



          I tried creating a table test.foo with 1 row, and updated the row with a series of transactions. I can then use Jeremy Cole's script to dump the page:



          innodb_space -s ibdata1 -T test/foo -p 3 page-dump

          ...

          records:
          :format=>:compact,
          :offset=>125,
          :header=>
          :next=>112,
          :type=>:conventional,
          :heap_number=>2,
          :n_owned=>0,
          :min_rec=>false,
          :deleted=>false,
          :nulls=>[],
          :lengths=>,
          :externs=>[],
          :length=>5,
          :next=>112,
          :type=>:clustered,
          :key=>[:name=>"id", :type=>"BIGINT UNSIGNED", :value=>7],
          :row=>[],
          :sys=>
          [:name=>"DB_TRX_ID", :type=>"TRX_ID", :value=>2843,
          :name=>"DB_ROLL_PTR",
          :type=>"ROLL_PTR",
          :value=>
          :is_insert=>true, :rseg_id=>20, :undo_log=>:page=>335, :offset=>272],
          :length=>21,
          :transaction_id=>2843,
          :roll_pointer=>
          :is_insert=>true, :rseg_id=>20, :undo_log=>:page=>335, :offset=>272


          You can see under the :sys key there's the DB_TRX_ID. As I make further updates to the row, this value is changed. You can try it yourself and see how the value changes.



          Read Jeremy's series of blog posts to understand more about the InnoDB format:



          Here's a list of his blog posts: https://blog.jcole.us/innodb/







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Mar 24 at 22:21









          Bill KarwinBill Karwin

          391k65526682




          391k65526682












          • My pleasure. Remember it is traditional on Stack Overflow to upvote an answer that helps you, or mark as "accepted" the answer that really answers your question fully. See stackoverflow.com/help/someone-answers

            – Bill Karwin
            Mar 25 at 12:23






          • 1





            my bad. I first vote the answer and it turns out that I'm the new comer for the stack overflow and my vote can't be used to influence the rank. so I just give up other actions like accepted the answer.

            – Keyang Ma
            Mar 25 at 20:46

















          • My pleasure. Remember it is traditional on Stack Overflow to upvote an answer that helps you, or mark as "accepted" the answer that really answers your question fully. See stackoverflow.com/help/someone-answers

            – Bill Karwin
            Mar 25 at 12:23






          • 1





            my bad. I first vote the answer and it turns out that I'm the new comer for the stack overflow and my vote can't be used to influence the rank. so I just give up other actions like accepted the answer.

            – Keyang Ma
            Mar 25 at 20:46
















          My pleasure. Remember it is traditional on Stack Overflow to upvote an answer that helps you, or mark as "accepted" the answer that really answers your question fully. See stackoverflow.com/help/someone-answers

          – Bill Karwin
          Mar 25 at 12:23





          My pleasure. Remember it is traditional on Stack Overflow to upvote an answer that helps you, or mark as "accepted" the answer that really answers your question fully. See stackoverflow.com/help/someone-answers

          – Bill Karwin
          Mar 25 at 12:23




          1




          1





          my bad. I first vote the answer and it turns out that I'm the new comer for the stack overflow and my vote can't be used to influence the rank. so I just give up other actions like accepted the answer.

          – Keyang Ma
          Mar 25 at 20:46





          my bad. I first vote the answer and it turns out that I'm the new comer for the stack overflow and my vote can't be used to influence the rank. so I just give up other actions like accepted the answer.

          – Keyang Ma
          Mar 25 at 20:46



















          draft saved

          draft discarded
















































          Thanks for contributing an answer to Stack Overflow!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55327342%2fwill-db-trx-id-hidden-field-modified-smaller-than-it-use-be%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          SQL error code 1064 with creating Laravel foreign keysForeign key constraints: When to use ON UPDATE and ON DELETEDropping column with foreign key Laravel error: General error: 1025 Error on renameLaravel SQL Can't create tableLaravel Migration foreign key errorLaravel php artisan migrate:refresh giving a syntax errorSQLSTATE[42S01]: Base table or view already exists or Base table or view already exists: 1050 Tableerror in migrating laravel file to xampp serverSyntax error or access violation: 1064:syntax to use near 'unsigned not null, modelName varchar(191) not null, title varchar(191) not nLaravel cannot create new table field in mysqlLaravel 5.7:Last migration creates table but is not registered in the migration table

          용인 삼성생명 블루밍스 목차 통계 역대 감독 선수단 응원단 경기장 같이 보기 외부 링크 둘러보기 메뉴samsungblueminx.comeh선수 명단용인 삼성생명 블루밍스용인 삼성생명 블루밍스ehsamsungblueminx.comeheheheh

          155 수학 과학 기타 둘러보기 메뉴eh추가해eh문서를 완성해