Results 1 to 6 of 6
  1. #1
    Join Date
    Jan 2004
    Location
    Montreal, Canada
    Posts
    151

    Unanswered: selecting and inserting data into another DB

    Iam farely new to this so sorry for the newbie question.. but how do you select all data from one table and insert that data into the same table but in another sql database.

  2. #2
    Join Date
    Jul 2002
    Location
    Village, MD
    Posts
    621
    Use database name:

    insert seconddb.dbo.table
    select * from firstdb.dbo.table

  3. #3
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    Hey!

    How come you get all the hard questions.....

    EDIT: But I think you should list out the column names....is this a one time (the BIGGEST lie in IT) thing?

    What are you trying to accomplish?
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  4. #4
    Join Date
    Jul 2002
    Location
    Village, MD
    Posts
    621
    Originally posted by Brett Kaiser
    Hey!

    How come you get all the hard questions.....
    Ok - now it is your turn....
    Last edited by snail; 01-28-04 at 15:16.

  5. #5
    Join Date
    Jan 2004
    Location
    Montreal, Canada
    Posts
    151
    yes this is a one shot thing

  6. #6
    Join Date
    Jan 2004
    Location
    Montreal, Canada
    Posts
    151
    thanks you guys

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •