Solved

Excel Table Import into SQL Server 2008

Posted on 2014-07-27
5
734 Views
Last Modified: 2014-07-28
I created a new database called Temp, I used Task/Import to import a table from excel. The table is there and I can query the table and see it's contents. When I try to do a join on the table I get the error below.

Msg 7202, Level 11, State 2, Line 1
Could not find server 'Temp' in sys.servers. Verify that the correct server name was specified. If necessary, execute the stored procedure sp_addlinkedserver to add the server to sys.servers.
0
Comment
Question by:imnee
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 15

Expert Comment

by:Ess Kay
ID: 40223039
save it as a comma delimited  file,  and create an sql to read through the file and insert them
0
 
LVL 15

Expert Comment

by:Ess Kay
ID: 40223044
0
 
LVL 13

Accepted Solution

by:
Russell Fox earned 500 total points
ID: 40223301
The problem isn't with the server, it with the query - can you post some or all of the query so we can troubleshoot it? It sounds like you're using an incorrect name: server.database.schema.object. My guess is that the join should be "JOIN dbo.Temp ON..."
0
 

Author Closing Comment

by:imnee
ID: 40223974
Correct. I have the column name CompanyPartMasterId as part of the reference to my table.

INNER JOIN Company.dbo.Plating.CompanyPartMasterId spm1 on spm1.CompanyPartMasterId = spm.Company_Part_Master_ID
0
 
LVL 13

Expert Comment

by:Russell Fox
ID: 40224526
So you took out the column in the join?
INNER JOIN Company.dbo.Plating spm1
    ON spm1.CompanyPartMasterId = spm.Company_Part_Master_ID
0

Featured Post

Use Case: Protecting a Hybrid Cloud Infrastructure

Microsoft Azure is rapidly becoming the norm in dynamic IT environments. This document describes the challenges that organizations face when protecting data in a hybrid cloud IT environment and presents a use case to demonstrate how Acronis Backup protects all data.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
Via a live example, show how to shrink a transaction log file down to a reasonable size.
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.

735 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question