Blog

python tutorials and learn python

Created with Sketch.

MySQL Replace String Function

MySQL Replace String Function Summary: in this tutorial, we will show you how to use the MySQL REPLACE string function to replace a substring by another in a string. Introduction to MySQL REPLACE string function MySQL provides you with a useful string function called REPLACE that allows you to replace a string in a column of a…
Read more

MySQL LTRIM Function

MySQL LTRIM Function Summary: in this tutorial, you will learn how to use the LTRIM() function to remove all leading spaces of a string. MySQL LTRIM() function overview The LTRIM() function takes a string argument and returns a new string with all the leading space characters removed. The following illustrates the syntax of the LTRIM()…
Read more

MySQL LOWER Function

MySQL LOWER Function Summary: in this tutorial, you will learn how to use the MySQL LOWER() function to return the lowercase of a string. MySQL LOWER() function overview The LOWER() function accepts a string argument and returns the lowercase version of that string. Here is the syntax of the LOWER() function: LOWER(str) Code language: SQL…
Read more

MySQL LEFT Function

MySQL LEFT Function Summary: in this tutorial, you will learn how to use the MySQL LEFT function to return the left part of a string with a specified length. Introduction to MySQL LEFT function The LEFT function is a string function that returns the left part of a string with a specified length. The following…
Read more

MySQL String Length

MySQL String Length Summary: in this tutorial, you will learn about MySQL string length functions that allow you to get the length of strings measured in bytes and in characters. MySQL supports various character sets such as latin1, utf8, etc. You use the SHOW CHARACTER SET  statement to get all character sets supported by MySQL…
Read more

MySQL INSTR Function

MySQL INSTR Function Summary: this tutorial shows you how to use the MySQL INSTR function to return the position of the first occurrence of a string. Introduction to the MySQL INSTR function Sometimes, you want to locate a substring in a string or to check if a substring exists in a string. In this case,…
Read more

MySQL CONCAT Function

MySQL CONCAT Function Summary: in this tutorial, you will learn various ways to concatenate two or more strings together by using the MySQL CONCAT and CONCAT_WS functions. To concatenate two or more quoted string values, you place the string next to each other as the following syntax: SELECT ‘MySQL ‘ ‘String ‘ ‘Concatenation’; Code language:…
Read more

MySQL String Functions

MySQL String Functions This page shows you the most commonly used MySQL string functions that allow you to manipulate character string data effectively. Name Description CONCAT Concatenate two or more strings into a single string INSTR Return the position of the first occurrence of a substring in a string LENGTH Get the length of a…
Read more

MySQL YEAR Function

MySQL YEAR Function Summary: in this tutorial, you will learn how to use the MySQL YEAR function to get the year out of a date value. Introduction to MySQL YEAR function The YEAR() function takes a date argument and returns the year of the date. See the syntax of the YEAR() function: YEAR(date); Code language:…
Read more

MySQL WEEKDAY Function

MySQL WEEKDAY Function The WEEKDAY function returns a weekday index for a date i.e., 0 for Monday, 1 for Tuesday, … 6 for Sunday. The following illustrates the WEEKDAY function: WEEKDAY(date) Code language: SQL (Structured Query Language) (sql) The WEEKDAY function accepts 1 argument which is a DATE or DATETIME value. It returns an integer…
Read more