How to Use CURRENT_TIMESTAMP Function in SQL Server

CURRENT_TIMESTAMP Function in SQL Server

If the database developer wants to get the exact time of a system on which the SQL server is currently running, they can use the CURRENT_TIMESTAMP Function provided by SQL Server. The CURRENT_TIMESTAMP() function returns the computer’s current time stamp in ‘YYYY-MM-DD hh:mm: ss.mmm’ format. This function is useful when we want to record additions or deletions … Read more

LOWER Function in SQL Server

LOWER Function in SQL Server Uppercase Literal String

In this SQL Server tutorial, you learn about the LOWER function in SQL Server. Where you will be introduced to the syntax of the LOWER() function. Then you will learn how to use the LOWER() function with uppercase, mixed-case string, and string containing the special characters. In the end, you will learn how to use … Read more

UPPER Function in SQL Server

UPPER Function in SQL Server Lowercase Literal String

In this SQL tutorial, you will learn about the UPPER Function in SQL Server, where you will learn how to transform the string to uppercase. Additionally, you will learn how to convert literal strings, mixed case strings, and other characters to uppercase using the UPPER() function. Finally, you will use the UPPER() function with table … Read more

REPLACE Function in SQL Server

REPLACE Function in SQL Server with Literal String

In this SQL Server tutorial, you will learn how to use the REPLACE function in SQL Server. Where you will understand the workings of the REPLACE() function, and how to use it with a literal string, collation, and table columns. REPLACE Function in SQL Server The REPLACE() function in SQL Server replaces the substring of … Read more

SQL Server STR Function

SQL Server STR Function Float to String Conversion

In this SQL Server tutorial, I will show you how to use the SQL Server STR function, where you will understand how to convert the number to a string. You will learn about how the STR() function can be useful in various situations. Then syntax of the STR() function, as well as how to check … Read more

SQL Server LTRIM Function

SQL Server LTRIM Function Remove Leading Spaces

In this SQL Server tutorial, you will learn about the SQL Server LTRIM function to remove the leading spaces from the character expression. Where you will understand the use of the LTRIM() function with literal string, and variable to remove the character from the string. Also, you will learn how to remove the specified character … Read more

SQL Server RTRIM Function

SQL Server RTRIM Function Remove Trailing Spaces From Literal String

In this SQL Server tutorial, you will learn about the SQL Server RTRIM function to truncate the spaces from the end of any string. Where you will understand the syntax of the RTRIM() function with how to use it with a literal string and variable. Also how to remove trailing characters based on the specified … Read more

CHAR Function in SQL Server

Char Function in SQL Server ASCII Code 67

In this SQL Server tutorial, I will show you how to use the CHAR function in SQL Server to get the character based on the provided integer value. You will learn about the syntax of the CHAR() function, and then find the character based on the provided code or integer value. Finally, you will understand … Read more

RIGHT Function in SQL Server

RIGHT Function in SQL Server with Product Table Column

In this SQL Server tutorial, you will learn how to use the RIGHT function in SQL Server to extract the rightmost character from the given string value. You will understand the process of extracting the characters from the right side of the literal string. Then from the string value within the table column and from … Read more

SQL Server Format Number with Commas without Decimal Places

SQL Server Format Number with Commas without Decimal Places Using Format() Function

In this SQL Server tutorial, you will learn about SQL Server format number with commas without decimal places. You will use the FORMAT() function to format the number with commas and without decimal places. Then use the LEFT() and LEN() functions together for the same purpose. SQL Server Format Number with Commas without Decimal Places … Read more