Results 1 to 5 of 5
  1. #1
    Join Date
    Jan 2008
    Posts
    3

    Question Unanswered: HowTo compare data from 2 different db-sources (xls,csv,sql server, mysql server)?

    Hello Guys,

    I'm searching for a way to compare informations from one database against another database.

    E.g. i want to check if serialnumbers of my first database (eg hardware.xls or hardware.csv ) are already stored in my sql server database.

    I know i can use sql querys (Joins) for that task but i don't know how i can access 2 different databases at the same time. Do i need a tool for it? Does Excel is able to compare those data? But how? I'm searching for that thread since 2 days testing with some tools without any success...

    So please help...

    Kindly Regards...

    Be

  2. #2
    Join Date
    Jan 2008
    Location
    Billings, MT
    Posts
    14
    There may be an easier way to do this, but you can use a linked server. Setup a new linked server in SQL Management Studio (under Server Objects) to point to your second database. Then you can write a query against tables in that database by referencing the tables in a format such as server.database.schema.table. You can even create views in your SQL Server database to make queries against the linked server easier. Hope that helps.
    Tom Rupsis
    Granite Peak Systems
    Phone: 406-672-8292
    Email: trupsis@granitepeaksys.com
    LinkedIn: www.linkedin.com/in/trupsis

  3. #3
    Join Date
    Jan 2008
    Posts
    3

    Red face

    Hello Tom,

    thx for your fast answer, but this didn't really helped me.

    1. I'm using SQL Server 2000 there is no Management Studio Software
    2. If I try to use the SQL Query Analyzer or the Enterprise Manager, how could i access the csv or .xls files?

    Maybe I didn't understand your answer...

    Greetings
    Be

  4. #4
    Join Date
    Jan 2008
    Location
    Billings, MT
    Posts
    14
    SQL 2000 can still create linked servers. Here's an article on how to do it, and they actually use an example of linking to Excel.

    http://www.databasejournal.com/featu...le.php/3085211
    Tom Rupsis
    Granite Peak Systems
    Phone: 406-672-8292
    Email: trupsis@granitepeaksys.com
    LinkedIn: www.linkedin.com/in/trupsis

  5. #5
    Join Date
    Jan 2008
    Posts
    3
    Hello Tom

    thx again for your answer. Now I found a way to compare my two databases (sql vs access)

    Linked Server was the right answer. After i had a connect to the access database i was able to use sql statements for comparing the mdb against the sql database.

    Thx a lot!

    Bye Be

Posting Permissions

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