Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7093931
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T08:30:02+00:00 2026-05-28T08:30:02+00:00

How to create a linked Server Query Server1 name is Server , Table name

  • 0

How to create a linked Server Query

Server1 name is Server, Table name is Employee
Server2 name is RAPAN, Table name is Venus

I want to select a venus table (server2) through server1.

How to do this through query

Tried Query

EXEC sp_addlinkedserver 
   @server = 'server', 
   @srvproduct = '',
   @provider = 'SQLOLEDB', 
   @datasrc = 'RAPAN'
GO

Query Executed Successfully, But when it try to select * from venus through server1, it’s giving error as invalid object name

What wrong in my query…

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T08:30:03+00:00Added an answer on May 28, 2026 at 8:30 am
    • You should add login mapping to this server
    • You should query with full naming convention like SELECT * FROM server1.RAPAN.dbo.venus

    To add linked server use (and play with options on your needs):

    EXEC sys.sp_addlinkedserver @server = 'RAPAN', @srvproduct = 'SQL Server'
    

    Set optional options

    EXEC sys.sp_serveroption @server = 'RAPAN', @optname = 'collation compatible', @optvalue = 'On'
    EXEC sys.sp_serveroption @server = 'RAPAN', @optname = 'data access', @optvalue = 'On'
    EXEC sys.sp_serveroption @server = 'RAPAN', @optname = 'lazy schema validation', @optvalue = 'On' 
    EXEC sys.sp_serveroption @server = 'RAPAN', @optname = 'rpc', @optvalue = 'On'
    EXEC sys.sp_serveroption @server = 'RAPAN', @optname = 'rpc out', @optvalue = 'On'
    

    Add login (And read more)

    EXEC sys.sp_addlinkedsrvlogin @rmtsrvname = 'RAPAN'
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to create two linked subforms on a form. For this I need
I need to create a linked server to a DB2 database on a mainframe.
How can I create View on Linked Server db. For Example I have a
Please explain what this task is about? Create a generic linked list class that
I have implemented a linked list as a self-referencing database table: CREATE TABLE LinkedList(
I am attempting to create a linked server from a 2005 to 2008 Microsoft
I'm trying to create a linked server in MS SQL Server 2005, pointing to
I have opened the Linked Server dialog to create a Linked Server so that
Is there a way to do SELECT A, B INTO [SERVER\INSTANCE_B].DATABASE.DBO.TABLE FROM [SERVER\INSTANCE_A].DATABASE.DBO.TABLE between
I created a linked server to my machine to query from other server using

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.