Difference between LEN() and DATALENGTH(), VARCHAR() AND NVARCHAR()
Hi,Yesterday one of my colleague asked me a question. He told that he created a table with 2 columns Name and Name1 with datatypes varchar(20) and nVarchar(20). He is entering the same values in both...
View ArticleSQL Server - How to get the list of Hard Disk and Free Space on SQL DB Server
SQL Server - How to get the list of Hard Disk and Free Space on SQL DB ServerThe below Stored Procedure will help to get the list of Hard Disk and its available free space on SQL DB...
View ArticleGenerate Random Passwords – SQL Server
Hi,Below is the simple method to generate random passwords.Query:selectsubstring(replace(cast(newid()asvarchar(50)),'-',''),1,10)The above query will generate random 10 digit passwords. The number can...
View Article“Consistency validation for SQL Server registry keys” failed. – SQL Server...
Hi,The below error occurs when we install SQL Server 2012.Rule “Consistency validation for SQL Server registry keys” failed. The SQL Server registry keys from a prior installation cannot be modified....
View ArticleHow to insert into a table which contains only one IDENTITY column
Hi,Question:I have a table with only one column. The column is of smallint datatype and is specified as identity. How to insert into that table?Answer:Let’s discuss this with a example.Create a table...
View ArticleCluster is not recognized as an internal or external command, operable...
Hi,Error Message:Cluster is not recognized as an internal or external command, operable program or batch fileSolution: 1. Go to Server Manager -> Manage -> Add Roles and Features...
View Article