Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. begintrans, commit and rollback

begintrans, commit and rollback

Scheduled Pinned Locked Moved Visual Basic
question
10 Posts 7 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    mabrahao
    wrote on last edited by
    #1

    hi, im doing a app on vb6 and i have a doubt about the transaction. how can i know if the transaction is "open" or not. thanks, Marcus

    G L D S 4 Replies Last reply
    0
    • M mabrahao

      hi, im doing a app on vb6 and i have a doubt about the transaction. how can i know if the transaction is "open" or not. thanks, Marcus

      G Offline
      G Offline
      Goutam Patra
      wrote on last edited by
      #2

      mabrahao wrote:

      app on vb6

      VB6 is dead.

      mabrahao wrote:

      how can i know if the transaction is "open" or not.

      As much as i can remember (asuming that you are using ADODB) the only way to use a variable. After opening the transaction make it true and after commit or rollback make it false.

      L G 2 Replies Last reply
      0
      • M mabrahao

        hi, im doing a app on vb6 and i have a doubt about the transaction. how can i know if the transaction is "open" or not. thanks, Marcus

        L Offline
        L Offline
        Lost User
        wrote on last edited by
        #3

        If you opened one, it's open (until commit or rollback is called). If you didn't open it, you probably won't be able to close it anyway. If I need a transaction, I tend to start it when the connection opens, and commit or rollback just before I close the connection again.

        I are Troll :suss:

        1 Reply Last reply
        0
        • G Goutam Patra

          mabrahao wrote:

          app on vb6

          VB6 is dead.

          mabrahao wrote:

          how can i know if the transaction is "open" or not.

          As much as i can remember (asuming that you are using ADODB) the only way to use a variable. After opening the transaction make it true and after commit or rollback make it false.

          L Offline
          L Offline
          Lost User
          wrote on last edited by
          #4

          Goutam Patra wrote:

          VB6 is dead

          Is that your answer if a customer asks whether you can change his/her code? :)

          I are Troll :suss:

          G 1 Reply Last reply
          0
          • M mabrahao

            hi, im doing a app on vb6 and i have a doubt about the transaction. how can i know if the transaction is "open" or not. thanks, Marcus

            D Offline
            D Offline
            David Mujica
            wrote on last edited by
            #5

            If you are using MS-SQL, this might help you determine how many transactions are running ... select @@TranCount AS TransactionCount

            1 Reply Last reply
            0
            • G Goutam Patra

              mabrahao wrote:

              app on vb6

              VB6 is dead.

              mabrahao wrote:

              how can i know if the transaction is "open" or not.

              As much as i can remember (asuming that you are using ADODB) the only way to use a variable. After opening the transaction make it true and after commit or rollback make it false.

              G Offline
              G Offline
              Gregory Gadow
              wrote on last edited by
              #6

              Goutam Patra wrote:

              VB6 is dead.

              More accurate to say that it is undead: Microsoft hasn't supported it in years, but many companies are too (censored) cheap to buy upgraded software, or have solutions developed in-house that "work fine, so why bother going through the cost and hassle of rewriting it in a new language?" Like COBOL and RPG, VB6 (and earlier) will be around until the last corporate manager is mouldering in his grave.

              1 Reply Last reply
              0
              • L Lost User

                Goutam Patra wrote:

                VB6 is dead

                Is that your answer if a customer asks whether you can change his/her code? :)

                I are Troll :suss:

                G Offline
                G Offline
                Goutam Patra
                wrote on last edited by
                #7

                Well that was not my intention. Yes, some of my clients are still using good old VB6 application. And I told them I will not be able to give any more functionality in this application platform, I can give you support up to some minor changes. I think there is no point of doing any further development on VB6. And that’s why I said so. And I also I gave OP the some solution also. I just didn’t reply OP to say that.

                R 1 Reply Last reply
                0
                • G Goutam Patra

                  Well that was not my intention. Yes, some of my clients are still using good old VB6 application. And I told them I will not be able to give any more functionality in this application platform, I can give you support up to some minor changes. I think there is no point of doing any further development on VB6. And that’s why I said so. And I also I gave OP the some solution also. I just didn’t reply OP to say that.

                  R Offline
                  R Offline
                  Rajesh Anuhya
                  wrote on last edited by
                  #8

                  Goutam Patra wrote:

                  I think there is no point of doing any further development on VB6.

                  They can't not do .., because of client requirement., some client are still using windows98 with low and configuration systems which are not supported by .Net environment., they don't want to invest/upgrade their systems. In this case there is no chance for Programmers :( :( :(

                  Rajesh B --> A Simple Programmer <--

                  G 1 Reply Last reply
                  0
                  • R Rajesh Anuhya

                    Goutam Patra wrote:

                    I think there is no point of doing any further development on VB6.

                    They can't not do .., because of client requirement., some client are still using windows98 with low and configuration systems which are not supported by .Net environment., they don't want to invest/upgrade their systems. In this case there is no chance for Programmers :( :( :(

                    Rajesh B --> A Simple Programmer <--

                    G Offline
                    G Offline
                    Goutam Patra
                    wrote on last edited by
                    #9

                    Rajesh Puli wrote:

                    In this case there is no chance for Programmers

                    I agree

                    1 Reply Last reply
                    0
                    • M mabrahao

                      hi, im doing a app on vb6 and i have a doubt about the transaction. how can i know if the transaction is "open" or not. thanks, Marcus

                      S Offline
                      S Offline
                      Skynet_Code
                      wrote on last edited by
                      #10

                      You can check if <>.State equals 'adStateOpen' constant.

                      1 Reply Last reply
                      0
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      • Login

                      • Don't have an account? Register

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • World
                      • Users
                      • Groups