Linking to SQL Server using DG4ODBC

Hi all,
I've configured Oracle 11g R1 for Windows 2003 Server 32-bit to connect to MS SQL Server 2005 through ODBC.
Following is the error I got when I try to access SQL Server by the db link in Oracle:
SQL> select sysdate from dual@sqls ;
select sysdate from dual@sqls
ERROR at line 1:
ORA-28545: error diagnosed by Net8 when connecting to an agent
Unable to retrieve text of NETWORK/NCR message 65535
ORA-02063: preceding 2 lines from SQLSThe ODBC link to the SQL Server was successfully tested.
The listener, however, returned error as shown below.
/* The file E:\Oracle\OraDb11g\hs\admin\initsqls.ora */
HS_FDS_CONNECT_INFO = sqls
HS_FDS_TRACE_LEVEL = 1
/* Listener.ora */
LISTENER =
(ADDRESS_LIST=
      (ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521))
SID_LIST_LISTENER=
  (SID_LIST=
      (SID_DESC=
         (SID_NAME=sqls)
         (ORACLE_HOME=E:\Oracle\OraDb11g)
         (PROGRAM=dg4odbc)
/* tnsnames.ora */
sqls =
  (DESCRIPTION=
    (ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521))
    (CONNECT_DATA=(SID=sqls))
    (HS=OK)
/* sqlnet.ora */
SQLNET.AUTHENTICATION_SERVICES= (NTS)
NAMES.DIRECTORY_PATH= (TNSNAMES, EZCONNECT, HOSTNAME)
/* testing the connection */
E:\Oracle\OraDb11g\BIN>tnsping sqls
TNS Ping Utility for 32-bit Windows: Version 11.1.0.6.0 - Production on 14-JUN-2
010 09:36:35
Copyright (c) 1997, 2007, Oracle.  All rights reserved.
Used parameter files:
E:\oracle\OraDb11g\network\admin\sqlnet.ora
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION= (ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT
=1521)) (CONNECT_DATA=(SID=sqls)) (HS=OK))
OK (20 msec)
/* code to create the db link */
CREATE PUBLIC DATABASE LINK sqls CONNECT TO
"SRV11\Administrator" IDENTIFIED BY "ospassword" using 'sqls';
/* Contents of Listener Log */
Mon Jun 14 11:25:59 2010
14-JUN-2010 11:25:59 * trc_level * 0
14-JUN-2010 11:26:06 * (CONNECT_DATA=(CID=(PROGRAM=)(HOST=)(USER=Administrator))(COMMAND=status)(ARGUMENTS=64)(SERVICE=LISTENER)(VERSION=185599488)) * status * 0
Mon Jun 14 11:26:22 2010
14-JUN-2010 11:26:22 * (CONNECT_DATA=(SID=sqls)(CID=(PROGRAM=)(HOST=WORKGROUP\SRV10)(USER=SRV10\Administrator))) * (ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=3333)) * establish * sqls * 12505
TNS-12505: TNS:listener does not currently know of SID given in connect descriptorAny hint is appreciated.

You did create a DUAL table in the Sqlserver database?
Sybrand Bakker
Senior Oracle DBA

Similar Messages

  • Linking to SQL Server using Transparent Gateways

    I want to use the Transparent Gateways to link to a SQL Server DB.
    I downloaded Oracle Enterprise Server from OTN.
    As far as I can tell, the Transparent Gateways are supposed to be bundled with Oracle Enterprise Server, but I can't find them from the Universal Installer.
    Does anyone know how I install the Gateways? Are they included with the downloaded Oracle Enterprise Server? If not, do I need to get the Oracle Enterprise Server CD Pack?
    Thanks
    Mike

    You did create a DUAL table in the Sqlserver database?
    Sybrand Bakker
    Senior Oracle DBA

  • How can i get data from another database SQL Server use database link from

    I have a database link from Oracle connect to SQL Server database with user cdit connect default database NorthWind.How can I get data from another database(this database in this SQL Server use this database link)?

    hi,
    u should see following documentation:
    Oracle9i Heterogeneous Connectivity Administrator's Guide
    Release 1 (9.0.1)
    Part Number A88789_01
    in it u just go to chapter no. 4 (using the gateway),,u'll find ur answer there.
    regards
    umar

  • Link to SQL Server fails

    Oracle: 11gR2 on Linux and tryed following the instructions found on (therefore some generic stuff inside the files):
    http://www.gotodba.com/install-and-configure-db-link-to-sql-server-database-in-linux.html
    Steps:
    Step 1
    Installed FreeTDS and configured /etc/unixODBC/odbc.ini with the following:
    [ODBC Data Sources]
    MYDB2=IBM DB2 ODBC DRIVER
    SQLDB=FreeTDS
    [SQLDB]
    Driver = /usr/local/freetds/lib/libtdsodbc.so
    #Driver = /usr/lib64/libodbc.so
    Server = 10.0.0.9
    Database = komspom_kanc
    Port = 3488
    TDS_Version = 8.0
    Afterwards I can successfully login to the SQL server using:
    isql -v SQLDB <userid> <password>
    Step 2
    Created the initSQLDB.ora file in $ORACLE_HOME/hs/admin with the lines:
    # This is a sample agent init file that contains the HS parameters that are
    # needed for the Database Gateway for ODBC
    # HS init parameters
    HS_FDS_CONNECT_INFO = SQLDB
    HS_FDS_TRACE_LEVEL = 0
    HS_FDS_SHAREABLE_NAME = /usr/lib64/libodbc.so
    HS_DB_NAME = SQLDB
    HS_DB_DOMAIN = GOTODBA.COM
    HS_FDS_SUPPORT_STATISTICS = FALSE
    # ODBC specific environment variables
    set ODBCINI=/etc/unixODBC/odbc.ini
    # Environment variables required for the non-Oracle system
    #set <envvar>=<value>
    Step 3
    Added the following lines to listener.ora:
    SID_LIST_LISTENER_TWNYCSLD04=
    (SID_LIST=
    (SID_DESC =
    (ORACLE_HOME = /shared/app/komisija/product/11.2.0/dbhome_1)
    (SID_NAME = SQLDB)
    (PROGRAM = dg4odbc)
    (ENVS=LD_LIBRARY_PATH=/usr/lib64:/usr/local/freetds/lib:/shared/app/komisija/product/11.2.0/dbhome_1/lib)
    and reloaded the listener:
    lisnrctl reload
    Step 4
    Added the following line to tnsnames.ora:
    SQLDB =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = linux1.kons.gov.ba)(
    (CONNECT_DATA =
    (SERVICE_NAME = SQLDB)
    (HS = OK)
    afterwards tnsping SQLDB runs fine...
    Step 5
    Created a link as sys:
    create database link sqldb.gotodba.com
    connect to user
    identified by "password"
    using 'SQLDB';
    But after I run
    select * from "myTable"@sqldb.gotodba.com;
    I get:
    ERROR at line 1:
    ORA-28545: error diagnosed by Net8 when connecting to an agent
    Unable to retrieve text of NETWORK/NCR message 65535
    ORA-02063: preceding 2 lines from SQLDB.GOTODBA.COM
    What could be wrong and how to test where exactly shit hits the fan, pardon my language :)

    Ok, my bad... Was editing the listener.ora blindly instead of reading the documentation. I think ths should now be more or less correct?
    # listener.ora Network Configuration File: /shared/app/komisija/product/11.2.0/dbhome_1/network/admin/listener.ora
    # Generated by Oracle configuration tools.
    LISTENER =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
    (ADDRESS = (PROTOCOL = TCP)(HOST = linux1.kons.gov.ba )(PORT = 1521))
    ADR_BASE_LISTENER = /shared/app/komisija
    SID_LIST_LISTENER=
    (SID_LIST=
    (SID_DESC =
    (ORACLE_HOME = /shared/app/komisija/product/11.2.0/dbhome_1)
    (SID_NAME = SQLDB)
    (PROGRAM = dg4odbc)
    (ENVS=LD_LIBRARY_PATH=/usr/lib64:/usr/local/freetds/lib:/shared/app/komisija/product/11.2.0/dbhome_1/lib)
    lsnrctl status now returns:
    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521)))
    STATUS of the LISTENER
    Alias LISTENER
    Version TNSLSNR for Linux: Version 11.2.0.1.0 - Production
    Start Date 16-MAY-2011 20:03:38
    Uptime 0 days 0 hr. 5 min. 58 sec
    Trace Level off
    Security ON: Local OS Authentication
    SNMP OFF
    Listener Parameter File /shared/app/komisija/product/11.2.0/dbhome_1/network/admin/listener.ora
    Listener Log File /shared/app/komisija/diag/tnslsnr/linux1/listener/alert/log.xml
    Listening Endpoints Summary...
    (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
    (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=linux1.kons.gov.ba)(PORT=1521)))
    Services Summary...
    Service "SQLDB" has 1 instance(s).
    Instance "SQLDB", status UNKNOWN, has 1 handler(s) for this service...
    Service "orcl" has 1 instance(s).
    Instance "orcl", status READY, has 1 handler(s) for this service...
    Service "orclXDB" has 1 instance(s).
    Instance "orcl", status READY, has 1 handler(s) for this service...
    The command completed successfully
    However the select now returns:
    SQL> select * from "tblAktiCX"@sqldb;
    select * from "tblAktiCX"@sqldb
    ERROR at line 1:
    ORA-28500: connection from ORACLE to a non-Oracle system returned this message:
    And that's it..no error message... where to go from here?

  • How do i connect to sql server using java?

    hi ever body
    i need to connect to sql server using java
    what is the driver i will use?
    thanks

    Microsoft make a jdbc driver and it is readily available through MSDN. Here is a link http://msdn2.microsoft.com/en-us/data/aa937724.aspx. Whatever jdbc driver you are looking for, Google it, and if it exists you'll find it in 10 seconds.

  • ODBC Link ans SQL Server

    Hi!
    So I tried to create a ODBC link with SQL server, but there is a problem during the authentification process.
    When I try to use authentification thanks to SQL server, even with 'sa' user enabled, this error shows up
    Connection failed:
    SQLState: '28000'
    SQL Server Error: 18456
    [Microsoft][ODBC SQL Server Driver][SQL Server]Login failed for user 'myUser'.
    When I try to use authentification with Windows ID, another error shows up :
    Connection faled:
    SQLState: '28000'
    SQL Server Error: 18452
    [Microsoft][ODBC SQL Server Driver][SQL Server]Login failed. The login is from an untrusted domain and cannot be used with Windows authentication.
    The server is a VPS server and there is no domain to configure.
    I already tried to switch to mixed authentification, with it I can easily connect to SQL server with SQL server Management Studio. I also already browsed SQL Server Configuration Manager in order to set a static (not dynamic) port, TCP/IP are enabled in SQL
    server Network Configuration / Protocols for SQLEXPRESS but it still doesn't work. Ofc I restarted SQL server several times and I even tried to uninstall/reinstall it.
    Finally, this error shows up when I start SQL Server agent with SQL server Configuration Manager.
    >The request failed or the service did not respond in a timely fashion. Consult the event log or other applicable error logs for details.
    I tried to find out what is the problem by reading the logs but there is nothing about the failed authentification attempts there. It only shows some services starting or stopping.
    I read somewhere that it the VIA protocol could be the problem, but I can't find it anywhere in SQL Server Configuration Manager.
    I've been struggling for days with this. you're my only hope
    thanks!

    I juste forgot to explain that I have to do this for a client who will use a software of my company and this software needs this ODBC link to communicate with SQL Server. Also the users will connect to the server in TSE (so the application will be on the
    same server than SQL Server). I don't know if this detail is important but I prefer specify.
    "If it works in SSMS to connect with a SQL Login, then it should work with ODBC by using the same server name/credentials from the sam Client."
    I entered 'sa' user and another user that I created in SQL Server but I have the same error (login fail for user)
    "Are remote Connections enabled? Is a Firewall running on server and/or Client side? If so unblock the required TCP and UDP ports."
    Remote Connections are enabled on the server and there's just Windows Firewall on the server. I unblocked resquired TCP and UDP Ports. Even with the Windows Firewall turned off I have this problem. 

  • How to connect sql server using oracle Client

    Hi,
    I am working in oracle9i and windows os 32 bit.
    I need to connect SQL server 2000 from my oracle client..
    I heard about heterogeneous connectivity ...
    Please expalin me the steps what to add and how to connect the sql server...
    Regs....

    Are you trying to connect to SQL Server from your Oracle database (i.e. create a database link in Oracle to SQL Server)? Or are you trying to connect to SQL Server using your Oracle client software (i.e. SQL*Plus)?
    The former just requires Heterogeneous Services with Generic Connectivity. The latter is functionality that has been depricated and probably no longer works in your environment.
    Justin

  • How to store jpeg images in SQL server using NI database Connectivity Toolset. Can anyone please help me in this regard.

    Please tell how to store jpeg images in SQL Server using NI Database Connectivity Toolset.

    http://www.w3schools.com/sql/sql_datatypes.asp
    You setup a field as BLOB and store the binary of the picture there. Depending on the database it can be called differently as you can see in the link, in SQL server there's even a Image datatype.
    /Y
    LabVIEW 8.2 - 2014
    "Only dead fish swim downstream" - "My life for Kudos!" - "Dumb people repeat old mistakes - smart ones create new ones."
    G# - Free award winning reference based OOP for LV

  • Is sql server using trigger to capture change data in SQL server CDC?

    hi all,
    what is the Architecture of SQL server change data capture(CDC)? is sql server using trigger to capture change data in SQL server CDC? for example Change Data Capture (CDC) in SQL Server 2008 using we can capture change Data records INSERTs, UPDATEs, and
    DELETEs applied to SQL Server tables.so my question is SQL server using triggers to capture change data like INSERT TRIGGER, UPDATE TRIGGER and DELETED TRIGGER using each tables after enabled CDC...?
    Thanks
    Tharindu Dhaneenja 
    Tharindu Dhaneenja http://dhaneenja.blogspot.com

    It is not using triggers. The source is the transaction log.
    Related link:
    Basics of Change Data Capture
    ...The source of change data for change data capture is the SQL Server transaction log. As inserts, updates, and deletes are applied to tracked source tables, entries that describe those
    changes are added to the log. The log serves as input to the change data capture capture process. This reads the log and adds information about changes to the tracked table’s associated change table. Functions are provided to enumerate
    the changes that appear in the change tables over a specified range, returning the information in the form of a filtered result set. The filtered result set is typically used by an application process to update a representation of the source in some external
    environment. ...
    Kalman Toth, SQL Server & Business Intelligence Training; SQL Server 2008 Training

  • How could I create a "Linked Server" link from SQL Server 2008R2 64-Bit to Oracle Database 11.2 64-Bit?

    How could I create a "Linked Server" link from SQL Server 2008R2 64-Bit to Oracle Database 11.2 64-Bit?
    Let's say the SQL Server and Oracle Database are in the same Company Internet Network.
    I have the code, but I do not know how to use it. Such as what is System DSN Name? Where could I get it. What does it look like?
    Do I need to install any Oracle Client Software in order to link from SQL Server to Oracle? Or SQL Server has the built-in drivers installed already that I can directly create a Linked Server from SQL Server to Oracle?
    I need to know details. Thanks.
    USE master
    go
    EXEC sp_addlinkedserver
         @server  = '{Linked Server Name}'
        ,@srvproduct = '{System DSN Name}'
        ,@provider  = 'MSDASQL'
        ,@datasrc  = '{System DSN Name}'
    EXEC sp_addlinkedsrvlogin
         @rmtsrvname = '{Linked Server Name}'
        ,@useself  = 'False'
        ,@locallogin = NULL
        ,@rmtuser  = '{Oracle User Name}'
        ,@rmtpassword = '{Oracle User Password}'

    You need an OLE DB provider for Oracle. There is one that ships with Windows, but it only supports very old versions of Oracle. Oracle has an OLE DB provider that you can use. I don't know if it's part of Oracle Client or how it is bundled.
    You should not use MSDASQL or any DSN.
    Erland Sommarskog, SQL Server MVP, [email protected]

  • Connecting SQL server using JavaScript

    I found an article on connecting SQL server using JavaScript. http://www.devarticles.com/c/a/JavaScript/Combining-North-Pole-with-South-Pole-JavaScript-with-SQL-Server-2000/
    Do you people think it's possible? i try out the code already but something wrong with it. I just copy and paste it to a html file but it comes out with error. Do I miss out something? Thanks.
    SY Tee

    Check the permissions and server authentication from the below link,
    http://technet.microsoft.com/en-us/library/ms179354(v=sql.90).aspx
    Regards, RSingh

  • Install SQL server using powershell

    Hi Team,
    Greetings!!!
    I want to install SQL server using powershell.
    Please guide me how can I install SQL server using powershell.
    I am trying to install using the command :  " Invoke-Item SQLIPAK /AS /QFE:11.0.3393 //SQLADMIN:REDMOND\PSITADM /CLEANMSDB /NOLOGCOPY /AUTOTEMPFILES /PREVIEW"
    But it is throwing error as:
    Invoke-Item : A positional parameter cannot be found that accepts argument '/AS'.
    At line:1 char:1
    + Invoke-Item SQLIPAK.exe /AS /QFE:11.0.3393 //SQLADMIN:REDMOND\PSITADM /CLEANMSDB ...
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        + CategoryInfo          : InvalidArgument: (:) [Invoke-Item], ParameterBindingException
        + FullyQualifiedErrorId : PositionalParameterNotFound,Microsoft.PowerShell.Commands.InvokeItemCommand

    Hello,
    Ref to links
    http://msdn.microsoft.com/en-us/library/ms144259.aspx
    http://www.mssqltips.com/sqlservertip/2707/installing-sql-server-2012-on-windows-server-core-using-powershell/
    Please mark this reply as the answer or vote as helpful, as appropriate, to make it useful for other readers

  • Taking snapshot of oracle tables to sql server using transactional replication is taking a long time

    Hi All,
    I am trying to replicate around 200 oracle tables onto sql server using transaction replication and it taking a long time i.e the initial snapshot is taking more than 24 hrs and it still going on.
    Is there any way to replicate those these tables faster?
    Kindly help me out..
    Thanks

    Hi,
    According to the description, I know the replication is working fine. But it is very slow. 
    1. Check the CPU usage on Oracle publisher and SQL Server. This issue may due to slow client processing (Oracle performance) or Network performance issues.
    2. Based on SQL Server 2008 Books Online ‘Performance Tuning for Oracle Publishers’ (http://msdn.microsoft.com/en-us/library/ms151179(SQL.100).aspx). You can enable the transaction
    job set and follow the instructions based on
    http://msdn.microsoft.com/en-us/library/ms147884(v=sql.100).aspx.
    2. You can enable replication agent logging to check the replication behavior. You may follow these steps to collect them:
    To enable Distribution Agent verbose logging. Please follow these steps:
    a. Open SQL Server Agent on the distribution server.
    b. Under Jobs folder, find out the Distribution Agent.
    c. Right click the job and choose Properties.
    d. Select Steps tap, it should be like this:
    e. Click Run agent and click Edit button, add following scripts by the end of scripts in the command box:
            -Output C:\Temp\OUTPUTFILE.txt -Outputverboselevel 2
    f. Exit the dialogs
     For more information about the steps, please refer to:
    http://support.microsoft.com/kb/312292
    Hope the information helps.
    Tracy Cai
    TechNet Community Support

  • When Deploying SSIS Packages to SQL Server using SSMS Import feature, is the package configuration file deployed at the same time?

    Hello, everyone,
    I have an SSIS package with a XML package configuration file. I deployed it to the sql server using the import feature in SSMS (in Stored Packages, right click MSDB, select Import, select the package to deploy in file system). My question is 
    Is the XML package configuration file also deployed? If so, which folder is it stored so that I can change the values in it? If not, is setting up the Configuration tab when scheduling a agent job the way to go manually bring the configuration file in?
    Your help and information is much appreciated.
    Regards

    Thank you Arthur for your reply. I appreciate it.
    A followup questions:
    I used direct setting for the configuration file path on C:\. But it needs to be on D:\ on the remote server. I can't create the D:\ path because I don't have D:\ drive on my computer (I understand I could use indirect setting to change the path in the remote
    server. But that's not the concern here).
    My question is:  since the configuration is not deployed, can I make it up by setting up the Configurations in creating the agent job step? That is, copy the configuration file to the D:\ drive on the remote server, in Configurations tab, add the configuration
    file on D:\ to the configuration. Will it work? Will the package still look for the original config file on C:\?  and if it doesn't find it there, will it cause any error?
    Thank you in advance for your help.
    Regards

  • Is it possible to use Jdeveloper with Other Sql Server using JDBC-ODBC bri

    I have been able to successfully establish connection with Sql server Using JDBC-ODBC bridge, but when i run the application and perform some operations such as insert the following errors occur:
    (oracle.jbo.SQLStmtException) JBO-27122: SQL error during statement preparation. Statement: SELECT ItmUnit.ORG_CODE, ItmUnit.UNIT_CODE, ItmUnit.UNIT_NAME, ItmUnit.ADDRESS1, ItmUnit.ADDRESS2, ItmUnit.ADDRESS3, ItmUnit.CITY_CODE, ItmUnit.USER_ID, ItmUnit.TIME_STAMP FROM ITM_UNIT ItmUnit
    ----- LEVEL 1: DETAIL 0 -----
    (java.sql.SQLException) [DataDirect][ODBC Sybase Wire Protocol driver]Sybase does not allow more than one active statement when retrieving results without a cursor
    (oracle.jbo.DMLException) JBO-26041: Failed to post data to database during "Insert": SQL Statement "INSERT INTO IMMS.HRM_UNIT(UNIT_CODE,UNIT_NAME) VALUES (?,?)".
    ----- LEVEL 1: DETAIL 0 -----
    (java.sql.SQLException) [Microsoft][ODBC SQL Server Driver]Connection is busy with results for another hstmt
    (oracle.jbo.AttrValException) JBO-27014: Attribute DeptCode in HrmUnitDept is required
    (oracle.jbo.SQLStmtException) JBO-27122: SQL error during statement preparation. Statement: SELECT HrmUnit.UNIT_CODE, HrmUnit.UNIT_NAME FROM IMMS.HRM_UNIT HrmUnit
    ----- LEVEL 1: DETAIL 0 -----
    (java.sql.SQLException) [Microsoft][ODBC SQL Server Driver]Connection is busy with results for another hstmt

    Yes, you can do that. For testing purposes you can also create simple files (with mkfile) and add these to ASM. That way you could also experiment with deleting files and see what happens in ASM
    Bjoern

Maybe you are looking for

  • I have a problem when I run the DTP

    hello the day before , I load  data in a PSA "MASTER DATA" mode full, then in the morning  I load data again this "MASTER DATA." I can see  that the same lines do not not present a problem but the lines were changed, i have a problem when I run the D

  • Column dependencies in a query

    I have a statement that gives me all the dependent ids that are dependent on id b from the table1. I need to join this table with another table to get correct order of these ids. Can any body help. Thanks in advance FOR REC IN (select distinct id fro

  • User license for IPCC

    I am try to verfiy the agent number a licenses I have for IPCCE v. 7.1. I've trying lookin in the C drive of the IP IVR but seem to not be able to find the file. can someone point me in the right direction.

  • Installing Acrobat XI on Macbook Air

    I own a copy of Acrobat XI on DVD, and need to install it on a MacBook Air. Can I download a copy from the Adobe site and use that instead? I already have a serial number.

  • 12 bit Image from a camera

    Hello, I'm acquiring some data from a x-ray detector. With each acquisition I obtain a column of the image that I want. The problem is that after n iteration I have a matrix of pixel values 192xN (with N=n.of iterations) see image attached for an exa