We were getting a Application Event Log Error from SharePoint Foundation with 5586 after you install SP1 with the following error:Unknown SQL Exception 2812 occurred. Additional error information from SQL Server is included below. Could not find stored procedure ‘proc_UpdateStatisticsNVP’.
It looks like SP1 added a new stored procedure called proc_UpdateStatisticsNVP which was executed from proc_UpdateStatistics, unfortunately it didn’t do this on all the databases. So I create the procedure in each of the databases that had proc_UpdateStatisticsNVP, sample code is attached.