none
Materialized View Error 8908

    Question

  • Microsoft SQL Server 2005 - 9.00.1187.07

    dbcc checkdb is failing with an interesting message:


    Msg 8908, Level 16, State 1, Line 1

    Indexed view 'BritishEnglishMV' (object ID 226099846) does not contain all rows that the view definition produces. Refer to Books Online for more information on this error. This does not necessarily represent an integrity issue with the data in this database.

    The data materialized in the indexed view is exactly the same as the data in the underlying tables...    


    Books online has no info on this error.
    Rebuilding the index fixes the problem.

    Thursday, July 28, 2005 12:19 AM

Answers

  • This warning is produced if the indexed view does not 100% match the "newly generated" indexed view. This may happen in cases when there are updates performed on the underlying tables.
    I will use an example to explain. If a view contains for examle an aggregation SUM, then inserting of new value to underlying table will add a new value to this sum. If the SUM was produced originally from a sequence of numbers, say a1, a2, ..., an, and the new inserted value is bb, then updating the indexed view means
    (a1+a2+a3+...+an) + bb while recalculating the indexed view may prform the sum in different order.
    We are still working on providing more information about warnings and errors we generate. This should improve substantially by the time we ship the final release of SQL Server 2005.

    Lubor Kollar
    Friday, July 29, 2005 12:22 AM

All replies

  • This warning is produced if the indexed view does not 100% match the "newly generated" indexed view. This may happen in cases when there are updates performed on the underlying tables.
    I will use an example to explain. If a view contains for examle an aggregation SUM, then inserting of new value to underlying table will add a new value to this sum. If the SUM was produced originally from a sequence of numbers, say a1, a2, ..., an, and the new inserted value is bb, then updating the indexed view means
    (a1+a2+a3+...+an) + bb while recalculating the indexed view may prform the sum in different order.
    We are still working on providing more information about warnings and errors we generate. This should improve substantially by the time we ship the final release of SQL Server 2005.

    Lubor Kollar
    Friday, July 29, 2005 12:22 AM
  • Hi Lubor,

    Can you please tell me how to resolve this issue. Because I am experiencing the same.

    Whether the Drop and recreating the View is the only option to get it resolved.

    Kindly advise.

     

    Thanks

    Ranjith


    Ranjith Kumar Mohandas
    Monday, August 08, 2011 1:45 PM
  • Please refer the artcicle:

    http://msdn.microsoft.com/en-us/library/ms189274.aspx

    Drop or recreate view/index only is the solution.


    Manish
    Friday, October 28, 2011 6:21 AM