Results 1 to 4 of 4

Thread: DBCOLUMNFLAGS_ISNULLABLE error on linked server....

  1. #1
    Join Date
    Mar 2003
    Posts
    383

    DBCOLUMNFLAGS_ISNULLABLE error on linked server....

    Server: Msg 7356, Level 16, State 1, Line 1 OLE DB provider 'SQLOLEDB' supplied inconsistent metadata for a column. Metadata information was changed at execution time.
    OLE DB error trace [Non-interface error: Column 'customerID' (compile-time ordinal 1) of object '"ABCDB"."dbo"."vwCustomer_xxxxk"' was reported to have a DBCOLUMNFLAGS_ISNULLABLE of 0 at compile time and 32 at run time].

    above error messages occurs when I try to run a proc which inside a query statement of select to a linked SQL6.5 database. The thing puzzled me is that
    linked query to run outside the proc is just fine, but errors within the proc. the running server is MSDE 2k with sp3. Look at knowledgebase about "
    DBCOLUMNFLAGS_ISNULLABLE" is only related to DB2 or SQL7 or SQL2000 before sp3.... man...
    thanks

  2. #2
    Join Date
    Nov 2002
    Location
    New Jersey, USA
    Posts
    3,932
    Just throwing out few ideas,

    try running stored procedure using WITH RECOMPILE option.

    Is customerid nullable or not nullable?

    It could be an issue with oledb driver?. Try creating linked server with ODBC driver?

  3. #3
    Join Date
    Mar 2003
    Posts
    383
    customerID is the PK, and tried about with recompile, still same error.

    further investigation: since the inside part of the query to the linked 6.5 is via a view, change to table, then found the error gone.

    looks like via view, the linked server is kind of confusing.
    thanks skhanal
    -D

  4. #4
    Join Date
    Sep 2007
    Posts
    1

    Workaround to issue

    I opened a case with Microsoft and got the following code from them. The operative clause in the connect string is "Early Metadata=True". Setting this gave me a working linked server. Here is the code that I used to create the linked server.

    EXEC sp_addlinkedserver
    @server='AXUSIR01',
    @srvproduct='Microsoft OLE DB Provider for DB2',
    @catalog='S102CD5C',
    @provider='DB2OLEDB',
    @provstr='Provider=DB2OLEDB;User ID=DTLD;Password=Dataload2;Initial Catalog=S102CD5C;Network Transport Library=TCP;Host CCSID=37;PC Code Page=1252;Network Address=10.100.200.4;Network Port=446;Package Collection=QGPL;Default Schema=XUNMDTTAXS;Process Binary as Character=False;Units of Work=RUW;DBMS Platform=DB2/AS400;Early Metadata=True;Defer Prepare=True;Rowset Cache Size=0;Persist Security Info=True;Mode=Read;Connection Pooling=True;Derive Parameters=False;Cache Authentication=True;'


    Hope this helps someone in the future.

Posting Permissions

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