This project has moved. For the latest updates, please go here.

"Clr Assembly must have main file specified" on a clear install of SSAS 2014 with 1.4.0/1.4.2

Topics: Developer Forum, User Forum
Nov 17, 2016 at 10:21 PM
Hello,

I think something went broken for SSAS 2014 version in ASSP 1.4.0. I'm doing the following:
  1. Create an Azure VM using a standard image "SQL Server 2014 SP2 Enterprise on Windows Server 2012 R2"
  2. Download a 1.4.0 version of the ASSP and unblock it (also placed it on C: drive)
  3. Start SSMS 2014 and try to add an assembly using UI => "Clr Assembly must have main file specified" error, the assembly is not added.

Here are the Fusion logs:

*** Assembly Binder Log Entry (11/17/2016 @ 9:38:06 PM) ***

The operation failed.
Bind result: hr = 0x8007000b. An attempt was made to load a program with an incorrect format.

Assembly manager loaded from: C:\Windows\Microsoft.NET\Framework\v4.0.30319\clr.dll
Running under executable C:\Program Files (x86)\Microsoft SQL Server\120\Tools\Binn\ManagementStudio\Ssms.exe
--- A detailed error log follows.

=== Pre-bind state information ===
LOG: Where-ref bind. Location = D:\assp_2014_v1_4_0\ASSP.dll
LOG: Appbase = file:///C:/Program Files (x86)/Microsoft SQL Server/120/Tools/Binn/ManagementStudio/
LOG: Initial PrivatePath = NULL
LOG: Dynamic Base = NULL
LOG: Cache Base = NULL
LOG: AppName = Ssms.exe

Calling assembly : (Unknown).

LOG: This bind starts in LoadFrom load context.
WRN: Native image will not be probed in LoadFrom context. Native image will only be probed in default load context, like with Assembly.Load().
LOG: Using application configuration file: C:\Program Files (x86)\Microsoft SQL Server\120\Tools\Binn\ManagementStudio\Ssms.exe.Config
LOG: Using host configuration file:
LOG: Using machine configuration file from C:\Windows\Microsoft.NET\Framework\v4.0.30319\config\machine.config.
LOG: Attempting download of new URL file:///D:/assp_2014_v1_4_0/ASSP.dll.
LOG: Assembly download was successful. Attempting setup of file: D:\assp_2014_v1_4_0\ASSP.dll
LOG: Entering run-from-source setup phase.
LOG: Assembly Name is: ASSP, Version=1.4.0.0, Culture=neutral, PublicKeyToken=null
ERR: Invalid assembly platform or ContentType in file (hr = 0x8007000b).
ERR: Run-from-source setup phase failed with hr = 0x8007000b.

ERR: Failed to complete setup of assembly (hr = 0x8007000b). Probing terminated.

The version 1.3.7 can be deployed with no problems.
Coordinator
Nov 18, 2016 at 12:02 AM
I believe Microsoft broke something SSMS, we are seeing similar issues on SSMS 2016. Have you tried running the XMLA script for ASSP? That should install OK.
Nov 18, 2016 at 7:30 PM
dgosbell wrote:
I believe Microsoft broke something SSMS, we are seeing similar issues on SSMS 2016. Have you tried running the XMLA script for ASSP? That should install OK.
Hello Darren,

SSMS 2016 indeed seems to have problems with SSAS assemblies, I've made a Connect ticket for the following issue: https://connect.microsoft.com/SQLServer/feedback/details/3111904/ssms-16-5-cant-delete-net-assemblies-from-a-ssas-2014-instance

Nevertheless I'm relatively sure, there is something wrong with ASSP 1.4.0/1.4.2 I'm not sure, but from the first glance ASSP starting from 1.4.0 is built as 64bit and not as AnyCPU. Is this potentially the source of the problem? On the same machine 1.3.7 is deployed successfully.

XMLA script works.
Dec 10, 2016 at 8:00 PM
Is it .Net Framework 4 ? if not then there's MS KB about this error:
https://support.microsoft.com/en-us/kb/2709869