sysindexes

  • When a server running sql 7.0 tries to get information from the sysindexes table of another server running sql 2000 ,following error occurs :

    OLE DB provider 'SQLOLEDB' supplied inconsistent metadata for a column. Metadata information was changed at execution time.

    The query i am running is :

    select rows

    FROM [serverRunningsql2000].[dbname].dbo.sysindexes

    where indid < 2

    AND id = 2007678200

    Querying any other table is fine,but sysindexes always gives that error.

    The servers are already linked.Any other query that is executed works fine ,but not any that queries the sysindexes table.

    What could be causing this error?

    Thanks in advance.

  • PattiKay,

    Check out article Q255097 from Microsoft. This is apparently a known issue however they do suggest a workaround. Hope this helps and have a great day!

    David

    David

    @SQLTentmaker

    “He is no fool who gives what he cannot keep to gain that which he cannot lose” - Jim Elliot

  • Good find on the KB article David. I don't reccommend workaround #1 .

    Patii, I'm curious to find out if workaround #2 works for you. Pelase let us know.

    Sean

  • Thanks David and Sean for your suggestions.Sean your right, workaround #1 is out of the question.

    Workaround #2 which is -->Create a view on the local server and then select from that view, instead of selecting from the view on the remote linked server.

    It did not work,so i did the oppposite,i created a view on the remote linked server which selects from sysindexes , so i do not query sysindexes directly.

    create view tot_att_vw

    as

    select rows from sysindexes

    where indid < 2

    and id = object_id("attendance_details")

    so in the stored procedure i will be running :

    select rows

    FROM [serverRunningsql2000].[dbname].dbo.tot_att_vw

    Though i am thinking of calling an sp instead of a view.

    Thanks again for your suggestions.

Viewing 4 posts - 1 through 3 (of 3 total)

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