T-SQL Function for Capitalize Word and Sentences

Hi folks, Today I faced a situation that I need to capitalize sentences in one column of a SQL Server database table, so I created a function to do that, I put this here to share with you. this function will change sentences like  : select dbo.Capitalize(‘sample text for capitalization!‘) to : Sample Text For Capitalization! Here Read more about T-SQL Function for Capitalize Word and Sentences[…]

T-SQL Script: Find Keyword in whole Database

There are some times that you need to find all occurrence (or some of them) of a keyword in all columns/tables in a database, This is a usual scenario in data profiling. I wrote script below to fulfill this requirement, this script will search for specific keyword in all columns and tables of a database Read more about T-SQL Script: Find Keyword in whole Database[…]

T-SQL Split Function : Split Field By a Delimiter

Hi, Today one of my colleagues in company faced a problem, He wants to split a text field by a delimiter character. This motivate me to write a Split function for my own use and put it here for help others. Suppose that our Primary Data is like this image and delimited by single slash Read more about T-SQL Split Function : Split Field By a Delimiter[…]

T-SQL Gregorian To Persian Converter

There are lots of times which you need a "Gregorian to Persian ( Shamsi ) Converter" in t-sql. below code will convert gregorian date string for example 2011-08-25 to persian or shamsi date string for example 1390-06-03 . just note this code will work on sql server 2005 or above because I used the Floor Read more about T-SQL Gregorian To Persian Converter[…]