DebugView tool [Download from https://docs.microsoft.com/en-us/sysinternals/downloads/debugview] Add Windows API declaration: Public Declare Sub Debug32 Lib “kernel32” Alias “OutputDebugStringA” (ByVal lpOutputString As String) print debug information like Debug32 “Print Info” Read more →
What is DevOps? When it needs?
DevOps is a combination of Software development (Dev) and Information-technology operations (Ops) It reduced the systems development life cycle. Provide continuous delivery with high software quality. Read more →
Update user password and set must change password on first login
net user “UserName” Password /logonpasswordchg:yes /logonpasswordchg:yes [For must change password on first login] Need to run under administrator right. Read more →
Area in MVC
What is Area in MVC. ASP.NET MVC 2 introduced Area. Area allows us to partition large application into smaller units where each unit contains separate MVC folder structure, same as default MVC folder structure Read more →
Custom Route Constraints
https://blogs.msdn.microsoft.com/webdev/2013/10/17/attribute-routing-in-asp-net-mvc-5/#custom-route-constraints Read more →
For branch creation of the [BranchName] form master branch
Git command: #Goto Master Branch git checkout master #make sure you have the latest files git pull #create new branch in your local repository git checkout –b <BranchName> #create remote branch with tracking git push –u origin <BranchName> Read more →
Get List of OLEDB
OleDbDataReader reader = OleDbEnumerator.GetEnumerator(Type.GetTypeFromProgID(“MSDAENUM”)); Read more →
Remove last commit after push
Get commit detail git log Reset head (last commit) form local repository 1. git reset –hard HEAD~1 2. git reset –hard HEAD^ Push to remote repository for remove last commit 1. git push -f <remote> <branch> 2. git push -f Reset stage file 1. git reset –hard HEAD <path/filename> Read more →
Get Table Detail
DECLARE @table_name SYSNAME SELECT @table_name = ‘dbo.TableName’ DECLARE @object_name SYSNAME , @object_id INT SELECT @object_name = ‘[‘ + s.name + ‘].[‘ + o.name + ‘]’ , @object_id = o.[object_id] FROM sys.objects o WITH (NOWAIT) JOIN sys.schemas s WITH (NOWAIT) ON o.[schema_id] = s.[schema_id] WHERE s.name + ‘.’ + o.name = @table_name AND o.[type] = ‘U’ AND o.is_ms_shipped =… Read more →
Get all foreign key constent from schema
SELECT K_Table = FK.TABLE_NAME, FK_Column = CU.COLUMN_NAME, PK_Table = PK.TABLE_NAME, PK_Column = PT.COLUMN_NAME, Constraint_Name = C.CONSTRAINT_NAME FROM INFORMATION_SCHEMA.REFERENTIAL_CONSTRAINTS C INNER JOIN INFORMATION_SCHEMA.TABLE_CONSTRAINTS FK ON C.CONSTRAINT_NAME = FK.CONSTRAINT_NAME INNER JOIN INFORMATION_SCHEMA.TABLE_CONSTRAINTS PK ON C.UNIQUE_CONSTRAINT_NAME = PK.CONSTRAINT_NAME INNER JOIN INFORMATION_SCHEMA.KEY_COLUMN_USAGE CU ON C.CONSTRAINT_NAME = CU.CONSTRAINT_NAME INNER JOIN ( SELECT i1.TABLE_NAME, i2.COLUMN_NAME FROM INFORMATION_SCHEMA.TABLE_CONSTRAINTS i1 INNER JOIN INFORMATION_SCHEMA.KEY_COLUMN_USAGE i2 ON i1.CONSTRAINT_NAME = i2.CONSTRAINT_NAME… Read more →