Saturday, March 21, 2020

Display Bangla Date using PHP

https://github.com/tomamuns/BanglaDate

BanglaDate

This simple php script will help to display bangla date in following format. e.g. আজঃ ১৭-পৌষ-১৪২৬ (বুধবার)
Use
include_once("./BanglaDate.php");
$bdate = new BanglaDate();

echo "".$bdate->PrintEngDate()."<br />";
echo "".$bdate->PrintBanglaDate()."<br />";

Saturday, September 9, 2017

Query to Identify Primary Table is being used as Reference in which Tables in the SQL Database

Just write down the PrimaryTableName
and execute below query.

SELECT OBJECT_NAME (FK.referenced_object_id) 'Referenced Table',
OBJECT_NAME(FK.parent_object_id) 'Referring Table',
FK.name 'Foreign Key',
COL_NAME(FK.referenced_object_id,
FKC.referenced_column_id) 'Referenced Column',
 COL_NAME(FK.parent_object_id,FKC.parent_column_id) 'Referring Column'
FROM sys.foreign_keys AS FK
INNER JOIN sys.foreign_key_columns AS FKC
ON FKC.constraint_object_id = FK.OBJECT_ID
WHERE OBJECT_NAME (FK.referenced_object_id) = 'PrimaryTableName'

If you want to check multiple Primary Table then just replace
OBJECT_NAME (FK.referenced_object_id) = 'PrimaryTableName' by
OBJECT_NAME (FK.referenced_object_id) in
('PrimaryTable1','PrimaryTable2','PrimaryTable2')

Wednesday, January 14, 2015

Simple solution for Crystal Report SP12 with Visual Studio 2013 on 64 bit OS

First of all, many many thanks to Don Williams (http://scn.sap.com/people/don.williams)

Issue: 
An unhandled exception of type 'System.IO.FileNotFoundException' occurred in mscorlib.dll

Additional information: Could not load file or assembly 'file:///C:\Program Files (x86)\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Common\SAP BusinessObjects Enterprise XI 4.0\win32_x86\dotnet1\crdb_adoplus.dll' or one of its dependencies. The system cannot find the file specified.

Solution: 
Simply add useLegacyV2RuntimeActivationPolicy="true" in startup tag in app.config file.

example: <startup useLegacyV2RuntimeActivationPolicy="true">