Application might need to store user login information in SQL Server database. of course, we can easily store it in a table with varchar column. But, any authorized user can view this information and may get exposed to others too by info leak.

Keep the information secure (inaccessible) is one way to protect organization data. Another way is to encrypt your data. There are many encryption algorithm available in the market and SQL Server has heavy security feature. For instance, you can encrypt entire database or you can protect specific object and etc.

In this article I will be showing you the use of two function that helps you save a sensitive information (password) in to a table.