SQL LIKE - W3Schools
Có thể bạn quan tâm
LIKE
The LIKE command is used in a WHERE clause to search for a specified pattern in a column.
You can use two wildcards with LIKE:
- % - Represents zero, one, or multiple characters
- _ - Represents a single character (MS Access uses a question mark (?) instead)
The following SQL selects all customers with a CustomerName starting with "a":
Example
SELECT * FROM Customers WHERE CustomerName LIKE 'a%'; Try it Yourself »The following SQL selects all customers with a CustomerName ending with "a":
Example
SELECT * FROM Customers WHERE CustomerName LIKE '%a'; Try it Yourself »The following SQL selects all customers with a CustomerName that have "or" in any position:
Example
SELECT * FROM Customers WHERE CustomerName LIKE '%or%'; Try it Yourself »The following SQL statement selects all customers with a CustomerName that starts with "a" and are at least 3 characters in length:
Example
SELECT * FROM Customers WHERE CustomerName LIKE 'a__%'; Try it Yourself » ❮ Previous ❮ SQL Keywords Reference Next ❯ ★ +1 Sign in to track progressTừ khóa » Câu Lệnh Not Like Trong Sql
-
Toán Tử LIKE Và NOT LIKE Trong SQL
-
Lệnh LIKE Và NOT LIKE Trong Oracle
-
Điều Kiện LIKE Trong SQL Server
-
Toán Tử LIKE Trong SQL
-
[SQL Server] Toán Tử LIKE Và NOT LIKE Trong SQL
-
SQL Server: LIKE Và NOT LIKE | V1Study
-
LIKE Trong SQL Server - Comdy
-
Toán Tử LIKE Trong SQL | Lập Trình Từ Đầu
-
(LIKE) Truy Xuất Dữ Liệu Dựa Theo Chuỗi Trong MySQL - Web Cơ Bản
-
Điều Kiện LIKE Trong SQL Server - GreenSQL
-
Toán Tử LIKE Trong SQL Tìm Kiếm Mẫu Chỉ định - BAC
-
Toán Tử LIKE Trong SQL - Kiến Càng
-
LIKE (Transact-SQL) - SQL Server - Microsoft Docs
-
Sử Dụng NOT LIKE Trong Oracle - HelpEx