OPENQUERY error: An unexpected NULL value was returned

  • crmitchell - Friday, April 6, 2018 8:53 AM

    Jeff Moden - Friday, April 6, 2018 6:10 AM

    crmitchell - Friday, April 6, 2018 4:45 AM

    A few things to consider

    Ensure you are using the correct datasource provider - there are at least two common ones for connecting to an iSeries and they do have differences in how they handle things.

    Any chance of you identifying the names, sources, and differences for those two common ones?

    If you need to do anything beyond SELECTS then check how RPCs have been configured on the iSeries

    How should they be configured and for what things beyond SELECTs?

    Its been a couple of years and I've moved companies so its not so easy to check but one is IBMDA400 and the other IBMDASQL - looks like there's a third as well IBMDARLA - these are the IBM supplied providers and are installed when Client Access is installed - check with your iSeries admins as to which version of Client Access you need. There are also the ones included with SQL server mentioned further up this thread. .
    For the configuration I had found a reference in IBMs blue or red book - their equivalent to BOL - there's a setting to allow remote calls if you want to be able to call an iSeries program (RPG or Synon) - I think it may relate to running UPDATES as well.

    Oh and don't forget the horrible meaningless 8 character all uppercase names for everything and also watch out for collation differences.

    I had to laugh out loud about the 8 character names, the date differences, and the collation differences.  Been there and survived.  Not a ride I enjoy actually being on.

    Thanks for the names you were talking about.  Like you, it's been a couple of years since I've had to do an install of the first 2 you mentioned.  There's also a joyous caveat on the IBMDA400 provider... I don't recall the exact code or file names (it's in our company WIKI, which I don't have access to right now) but two of the configuration files are created with a fault in the XML and they have to be repaired manually.  That info is not in any of the IBM or Windows manuals.  The internet DOES have its occasional gems. 😀

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

Viewing post 16 (of 15 total)

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