Snowflake Vs MS-SQL - Part 33 - INITCAP

     


INITCAP

Sometimes we need to provide strings/lines in a specific format as per the client's request.

Suppose you want to capitalize the first letter of each word in the string and all other letters appear in lowercase.  It needs special treatment, known as InitCap (Initial Capitalisation).



MS-SQL Server 

You can only achieve this differently. You need to write a function or couple of lines of code as below: 



In Snowflakewe don't need to write so many lines of code. We can use the inbuilt function INITCAP.


Also, this function gives you the flexibility to provide a delimiter that INITCAP uses as a separators for words in the input expression. 

In the below example, 'q' is used as the delimiter.




For more details, you can refer to the following INITCAP



Yogesh Shinde

LinkedInProfile

<<< Back Next >>> 

Comments

Popular posts from this blog

Snowflake Vs MS-SQL - Part 36 - SPLIT_TO_TABLE

Snowflake Vs MS-SQL - Part 63 - ON Clause & Cross Join