Results 1 to 2 of 2
  1. #1
    Join Date
    Jul 2003
    Location
    West Palm Beach FL
    Posts
    5

    Unanswered: Linked Server and db2/400

    I have defined a linked server for db2/400. I have a sp on the db2 and when I execute the squel command I do not see any results:

    Exec ('Call QGPL.getallcompanies') AT AS400SRV_IBMDASQL_OLEDB
    Result: Command(s) completed successfully.

    When I execute the same sp from iSeries navigator it shows me the result.

    Could data be placed in a buffer since I cannot see them??

    Also I am trying to change my query and use following (to see if that would show me the result):

    select * from openquery (AS400SRV_IBMDASQL_OLEDB, 'Exec ('Call QGPL.getallcompanies')').

    Here I get an error: Msg 102, Level 15, State 1, Line 1
    Incorrect syntax near 'Call'.

    Can anyone help???
    Last edited by snufse; 10-23-07 at 11:15.

  2. #2
    Join Date
    Jun 2004
    Location
    Long Island
    Posts
    696
    Try: (extra single quotes, not double)
    select * from openquery (AS400SRV_IBMDASQL_OLEDB, 'Exec (''Call QGPL.getallcompanies'')').

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •