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. Database & SysAdmin
  3. Database
  4. How to do insertion automatically

How to do insertion automatically

Scheduled Pinned Locked Moved Database
databasetutorial
5 Posts 5 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.
  • S Offline
    S Offline
    siddisagar
    wrote on last edited by
    #1

    Hi All, I have two databases Example -A1 and A2, both are linked in SQL Server2008. I am pulling 3 tables information from A1 database and putting it into A2. But I am doing this manually by running the below queries Example : insert into TMP_ITEMS select * from A1..DEX.items How to make this as a automatic process. Thanks, Vidya Sagar

    C P J 3 Replies Last reply
    0
    • S siddisagar

      Hi All, I have two databases Example -A1 and A2, both are linked in SQL Server2008. I am pulling 3 tables information from A1 database and putting it into A2. But I am doing this manually by running the below queries Example : insert into TMP_ITEMS select * from A1..DEX.items How to make this as a automatic process. Thanks, Vidya Sagar

      C Offline
      C Offline
      Chris Meech
      wrote on last edited by
      #2

      How about using a trigger on the insert. As each record is inserted into one database, a similar record can be inserted into the other. :)

      Chris Meech I am Canadian. [heard in a local bar] In theory there is no difference between theory and practice. In practice there is. [Yogi Berra] posting about Crystal Reports here is like discussing gay marriage on a catholic church’s website.[Nishant Sivakumar]

      Z 1 Reply Last reply
      0
      • S siddisagar

        Hi All, I have two databases Example -A1 and A2, both are linked in SQL Server2008. I am pulling 3 tables information from A1 database and putting it into A2. But I am doing this manually by running the below queries Example : insert into TMP_ITEMS select * from A1..DEX.items How to make this as a automatic process. Thanks, Vidya Sagar

        P Offline
        P Offline
        PIEBALDconsult
        wrote on last edited by
        #3

        I've done that with a Windows Service. You could also use a Windows Scheduled Task.

        1 Reply Last reply
        0
        • C Chris Meech

          How about using a trigger on the insert. As each record is inserted into one database, a similar record can be inserted into the other. :)

          Chris Meech I am Canadian. [heard in a local bar] In theory there is no difference between theory and practice. In practice there is. [Yogi Berra] posting about Crystal Reports here is like discussing gay marriage on a catholic church’s website.[Nishant Sivakumar]

          Z Offline
          Z Offline
          ZurdoDev
          wrote on last edited by
          #4

          Agreed. In my opinion, this is the best approach.

          There are only 10 types of people in the world, those who understand binary and those who don't.

          1 Reply Last reply
          0
          • S siddisagar

            Hi All, I have two databases Example -A1 and A2, both are linked in SQL Server2008. I am pulling 3 tables information from A1 database and putting it into A2. But I am doing this manually by running the below queries Example : insert into TMP_ITEMS select * from A1..DEX.items How to make this as a automatic process. Thanks, Vidya Sagar

            J Offline
            J Offline
            Jorgen Andersson
            wrote on last edited by
            #5

            You can also check out replication.[^]

            Light moves faster than sound. That is why some people appear bright, until you hear them speak. List of common misconceptions

            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