SQL Server Management Studio – Recognizing Other File Extensions

sql serverssms

I am using SSMS 2012. I am working with .PRC, .TAB, and .UDF files. I added these file extensions to SSMS so that it would treat them like .SQL files already via Tools > Options > Text Editor > File Extension, but recently SSMS has stopped recognizing these files (e.g. won't show them with color coding or allow me to run them against a database). Funnily enough when I remove a file extension from a file it then recognizes them because it has "Map extensionless files to SQL Query Editor" checked.

Does anyone know what the problem might be?

Best Answer

According to this Connect item, this bug was fixed in Service Pack 1.

However, if the issue persists, you can try this convoluted workaround posted over at SQLServerCentral by Marios Philippopoulos:

OK, got it to work with help from http://www.progtown.com/topic374931-sql-server-2012-rtm.html.

Opened regedit.exe as Administrator.

Then:

On [HKEY_CURRENT_USER\Software\Microsoft\SQL Server Management Studio\11.0\FileExtensionMapping\PRC] I changed the Default key value to {B5A506EB-11BE-4782-9A18-21265C2CA0B4}.

On [HKEY_CURRENT_USER\Software\Microsoft\SQL Server Management Studio\11.0\Default Editors\PRC] I changed the Custom key value to {B5A506EB-11BE-4782-9A18-21265C2CA0B4}.