AS400 DB2 SQL linked server to a MS SQL server

Posted on 2008-11-19
Last Modified: 2013-11-30

Like we have linked server queries on a MS SQl server to read/write etc to a AS400 DB2 table. I would like to do the reverse and read/write tables from a AS 400 DB2 server to MS SQL server.

Is this possible?


Question by:gardmanIT
    LVL 37

    Assisted Solution

    everything is possible !
    but you will need a middleware product such as ibm websphere federation server
    that product knows how to simulate various data sources (and sql server among them) as db2 database and enables to do what you desire

    your second approach is to use dts / ssis / tsql to pull the data out of as400 and insert it into your sql server
    LVL 32

    Accepted Solution

    a federation server is really expensive to buy and deploy.

    alternatively you can work with Java and JDBC on iSeries to access MS-SQL.

    another option is to use a JDBC/ODBC bridge like those by DataDirect.

    If you really insist on using RPG/COBOl, it is possible to write your own Application requester driver, plug it into the WRKRDBDIRE screen and then use it seamlessly via the CONNECT sql method.
    LVL 3

    Assisted Solution

    Do you need to write programs on a DB2 server (such as an i5) or do you just need to get data from the DB2 database over to the MS SQL server?  That is, do you need to obtain DB2 data on the DB2 server and process it directly on the DB2 server before linking to MS SQL server?  If you do not need to actually program on the DB2 server then you can pull from the DB2 server to MS SQL server via programs on the MS SQL server.

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Looking for New Ways to Advertise?

    Engage with tech pros in our community with native advertising, as a Vendor Expert, and more.

    When you hear the word proxy, you may become apprehensive. This article will help you to understand Proxy and when it is useful. Let's talk Proxy for SQL Server. (Not in terms of Internet access.) Typically, you'll run into this type of problem w…
    Introduction SQL Server Integration Services can read XML files, that’s known by every BI developer.  (If you didn’t, don’t worry, I’m aiming this article at newcomers as well.) But how far can you go?  When does the XML Source component become …
    Via a live example combined with referencing Books Online, show some of the information that can be extracted from the Catalog Views in SQL Server.
    This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function

    737 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

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now