Call DB2 database from sql stored procedure

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • barmatt80
    New Member
    • Dec 2007
    • 55

    Call DB2 database from sql stored procedure

    I am in need of calling a DB2 stored procedure from MS SQL server 2005. If this is all possible.

    The ultimate goal is to have a user open the vb.net program, enter the employee ssn, and it will return some employee information. The ssn would be passed from the program to the sql stored procedure, which inturn would pass along the ssn to the db2 stored procedure, which would return Employee first name, last name, annual, sick, other and family leave balances. Then i would display those items in text boxes in my vb.net program.

    So is this even possible? I am usre there is or might be a better option, but I don't know it. Any suggestions, starting points, books, or any other items to help me accomplish this?

    thanks!
  • iburyak
    Recognized Expert Top Contributor
    • Nov 2006
    • 1016

    #2
    I think your DBA can install DB2 drivers on your SQL server and link to DB2 database as a linked server. Then it would be easy to prefix any procedure with linked server name.
    See example here but as I said you need DB2 drivers installed:
    http://blogs.msdn.com/dotnetinterop/archive/2006/01/20/defining-a-db2-as-a-linked-server.aspx



    Good Luck.

    Comment

    Working...