Posts

Showing posts from May, 2013

Could not load file or assembly 'Microsoft.ReportViewer.Common, Version=xx.0.0.0, Culture=neutral, PublicKeyToken='xxx' or one of its dependencies.

Scenarios: -If you get the following errors:  Could not load file or assembly Microsoft.ReportViewer.Common Could not load file or assembly Microsoft.ReportViewer. ProcessingObjectModel Server Error in '/' Application. Parser Error Description:  An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately. Parser Error Message:  Could not load file or assembly 'Microsoft.ReportViewer.WebForms, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91' or one of its dependencies. The system cannot find the file specified.

Using NULLIF() To Prevent Divide-By-Zero Errors In SQL

In case you want to return zero, in case a zero devision would happen, you can use: SELECT ( 45 / NULLIF( 0, 0 ) ) AS value For every divisor that is zero, you will get a zero in the result set

SQL SERVER – Dividing of Two Integer to get Float Value

if you make simple devide you will get integer without round value so you need to cast int to float Ex : SELECT (CAST(Number1)AS FLOAT)/Number1) AS AnswerFloat1