November 10, 2012

Fusion Active Template Library (ATL)

ERROR:
Rule "Fusion Active Template Library (ATL)" failed.
A computer restart is required because of broken fusion ATL. You must restart your computer before you continue.



SOLUTION:
Go to setup media (SQL DVD) and install this package and it'll be solved after a restart ;-)

32bit: DVD\1033_ENU_LP\x86\Setup\sqlsupport_msi\sqlsupport.msi
64bit: DVD\1033_ENU_LP\x64\Setup\sqlsupport_msi\sqlsupport.msi

November 09, 2012

SQL Server cannot process this media family


ERROR:
Specified Cast is not valid (SqlManagerUI)

ERROR:
Msg 3241, Level 16, State 13, Line 1
The media family on device 'D:\1.bak' is incorrectly formed. SQL Server cannot process this media family.
Msg 3013, Level 16, State 1, Line 1
RESTORE DATABASE is terminating abnormally.

CAUSE:
- Microsoft SQL Database fails to restore from higher ms-sql version
- Restoring the backup from SQL 2008 to SQL 2005 instance
- Restoring SQL backup file from SQL 2012 to SQL 2008

SOLUTION:
- Upgrade your destination sql server to upper version
- Prepare SQL data script instead of sql data backup file

October 29, 2012

Load an assembly from a network location


Error:
Exception Message: Could not load file or assembly 'file:///Z:\PROJECT\bin\Debug\XYZ.dll' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515)

Exception Message: An attempt was made to load an assembly from a network location which would have caused the assembly to be sandboxed in previous versions of the .NET Framework. This release of the .NET Framework does not enable CAS policy by default, so this load may be dangerous. If this load is not intended to sandbox the assembly, please enable the loadFromRemoteSources switch. See http://go.microsoft.com/fwlink/?LinkId=155569 for more information.


System.NotSupportedException: An attempt was made to load an assembly from a network location which would have caused the assembly to be sandboxed in previous versions of the .NET Framework. This release of the .NET Framework does not enable CAS policy by default, so this load may be dangerous. If this load is not intended to sandbox the assembly, please enable the loadFromRemoteSources switch. See http://go.microsoft.com/fwlink/?LinkId=155569 for more information.


Solution:
It will be solved if you add a simple magic ;-) line to YOURPROJECT.exe.config file 
- Open YOURPROJECT.exe.config file from bin folder
- Add <loadFromRemoteSources enabled="true" /> to <runtime> tag

October 18, 2012

CREATE FILE encountered operating system error 5


Problem:
- CREATE FILE encountered operating system error 5(Access is denied.)
- CREATE FILE encountered operating system error 5(failed to retrieve text for this error. Reason: 15105) while attempting to open or create the physical file 'PATH\FILE.mdf'.
- CREATE FILE encountered operating system error 5(Access is denied.) while attempting to open or create the physical file 'PATH\FILE.mdf'.

Solution:
- Go to Control Panel > Administrative Tools > Services
- Right click on SQL SERVER (BLAH BLAH) and select the Properties
- Stop service
- Go to Log On tab and change the Log on as: to Local System Account
- Apply and Start service again ans enjoy ;-)