Four-Part Name

  • I had created linked server against oracle in sql server 2005

    How to access the tables of oracle with four-part name(not with openquery)

    can u give me the examples/syntax?

  • assuming your linked server was aliased as "MyOracle" this command should help:

    --list all the tables and their names

    EXEC sp_tables_ex MyOracle

    GO

    we have a "model" kind of schema withthe user "CHANGE_ME" as well as other users/databases

    select * from MyOracle..CHANGE_ME.TBCITY

    select * from MyOracle..PROD.INVOICES

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • The normal syntax would be: [linkedserver].[database].[schema].

    However, I don't have an oracle instance to test this with and since the linked server is probably pointing directly at the database I am not sure this is correct. Below are 2 articles that might help.

    here

    and here

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply