Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Error 4502: View or function XXX has more column names specified than columns defined

Posted on 2013-12-03
3
1,798 Views
Last Modified: 2013-12-11
Due to an unfortunate incident, an SQL Update which was in progress got interrupted, and as a result, one of my views in my master database is a bit unhappy.  When I start my SQL Server up from the command line I get this error:

Error: 4502, Severity: 16, State: 1.
View or function 'sys.dm_os_sys_info' has more column names specified than columns defined.

I know there is a system stored procedure known as sp_refreshview, but when I run it like this:

EXECUTE sp_refreshview 'sys.dm_os_sys_info'

Open in new window


I get the error:

Msg 15165, Level 16, State 1, Procedure sp_refreshsqlmodule_internal, Line 55
Could not find object 'sys.dm_os_sys_info' or you do not have permission.

I am presently running my SQL Server using the T902 switch, so that the script "sqlagent100_msdb_upgrade.sql" does not run and prevent the database from coming online.  I need to fix the abovementioned error prior to re-running this script.

Can anybody suggest a fix that I can apply to overcome the error
0
Comment
Question by:LesterClayton
  • 2
3 Comments
 
LVL 8

Expert Comment

by:Mohit Vijay
ID: 39692368
It seems that your table columns have been changed but you have not updated those in sys.dm_os_sys_info view

Error clearly says that whatever columns you have in this view, some of them are not available.
0
 
LVL 18

Accepted Solution

by:
LesterClayton earned 0 total points
ID: 39701821
Ended up removing the SQL Instance and reinstalling.
0
 
LVL 18

Author Closing Comment

by:LesterClayton
ID: 39710852
Reason: EE members were unable to assist me, apart from stating the obvious.
0

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
The Delta outage: 650 cancelled flights, more than 1200 delayed flights, thousands of frustrated customers, tens of millions of dollars in damages – plus untold reputational damage to one of the world’s most trusted airlines. All due to a catastroph…
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

789 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question