Results 1 to 7 of 7
  1. #1
    Join Date
    Dec 2007
    Posts
    3

    Unanswered: AS 400 Linked Server with SQL Server 2005 32-bit

    My problem is happening while adding a AS 400 Linked Server. I use

    EXEC sp_addlinkedserver @server='TEST1',
    @srvproduct='IBM AS400 OLE DB Provider',
    @datasrc ='10.36.0.101',
    @provider='IBMDA400',
    @provstr='Initial Catalog=QGPL;CCSID=37;PCCodePage=1252'

    But, it is not effective with IBM AS400 OLE Provider, It gets always time-out score.

    Can Anyone Help Me

  2. #2
    Join Date
    Dec 2007
    Posts
    3

    Linked Server Problem AS 400 with SQl Server 2005

    I added a linked server with Microsoft OLE DB Provider for DB2 patch. And it run successfuly on all querying physical files and some logical files.
    There is a specific errors while inquiring new created logical files. This is;

    Msg 7356, Level 16, State 1, Line 1
    The OLE DB provider "DB2OLEDB" for linked server "AS400IST" supplied inconsistent metadata for a column. The column "PSDLST" (compile-time ordinal 1) of object ""S657DC9B"."YDTSMST"."KTPSML00"" was reported to have a "DBCOLUMNFLAGS_ISNULLABLE" of 0 at compile time and 32 at run time.


    Why does it occur?

    Can anyone help me?

  3. #3
    Join Date
    Dec 2002
    Posts
    1,245
    I'm guessing that you fixed this particular issues, since you have not reported a follow on error with the DB2 provider.

    It's been a while since I linked an AS400, but from what I remember, the issue always boiled down to the login window. For a normal user install, the window pops up, you fill in the username and password and then march on. But for SQL Server linked servers, the window pops up on the virtual desktop and there's no one "there" to fill in user name and password. I seem to recall that we solved it by adding a user to the AS 400 with the same name and password as the service account that was running SQL Server.

    I also have a vague recollection that the account on the AS 400 was limited to 10 characters (for both username and password). That was a headache as it meant we had to change the service account under which our SQL database ran ('cause the account name was 11 characters long).

    Mind you, this was about 4 years ago with V5R4M0; things might be different now.

    Regards,

    hmscott
    Have you hugged your backup today?

  4. #4
    Join Date
    Dec 2002
    Posts
    1,245
    I googled the phrase "supplied inconsistent metadata for a column" (in quotes) and came up with a number of different sites, but they were for Oracle or Informix. They basically pointed in the direction of known defects on the provider side (ie, Oracle or Informix).

    I would guess:

    1) a defect (bug)

    2) a view that needs to be "refreshed" or recompiled after the underlying table (file in DB2 terms) has been changed.

    But those are just guesses.

    Regards,

    hmscott
    Have you hugged your backup today?

  5. #5
    Join Date
    Dec 2007
    Posts
    1
    I hava the same question about it...
    -------------------

  6. #6
    Join Date
    Dec 2007
    Posts
    3

    Exceptional ways to handle this error

    Today,

    I convert all logical files those are not inquiring by SQL Server to SQL Views.

    Then, There is not any error. And Queries run successfully.

    Regards.

  7. #7
    Join Date
    Sep 2009
    Posts
    1
    OleDB Provider always was problematic for me. I prefer creating an ODBC DSN, then use OleDB for ODBC. I never had problems with that.

Posting Permissions

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