Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
Mathias Wulff edited this pageDec 16, 2025 ·5 revisions

KeywordLIKE

Match expression with pattern.

Syntax:

    expressionLIKE pattern

The pattern syntax uses these special characters:

  • % - any amount of any character
  • _ - Exactly one character of any type
PatternRegexMatchesDoesn't Match
A%/^A[\\s\\S]*$/iA, AB, Apple, ANYTHINGBanana
%A/^[\\s\\S]*A$/iA, BA, PIZZAAB, Apple
_A/^.A$/iBA, CA, 1AA, AAA
A_/^A.$/iAB, A1, AZA, ABC
_4_/^.4.$/i444, a4b, X4Y4, 44, 404*
%4%/^[\\s\\S]*4[\\s\\S]*$/i4, 444, 1234, a4b123, abc

*Note: '404' does NOT match '4' because:

  • First character: '4' (matches_)
  • Second character: '0' (needs to match literal '4') ❌ FAILS
  • Third character: '4' (would match_)

In AlaSQL the match is case-insensitive meaning we are aligning with MySQL, MSSQL and SQLite.

DatabaseLIKE DefaultILIKE SupportNotes
PostgreSQLCase-SENSITIVE✅ Case-insensitiveILIKE is PostgreSQL extension
OracleCase-SENSITIVEUse UPPER()/LOWER() instead
MySQL/MariaDBCase-INSENSITIVE**Depends on collation (default: ci)
MSSQLCase-INSENSITIVE**Depends on collation (default: ci)
SQLiteCase-INSENSITIVE****ASCII only; case-sensitive for non-ASCII
AlaSQLCase-INSENSITIVE⚠️ Same as LIKEAll variants are case-insensitive

Please note that Postgres and Oracle behaves differently and the SQL might need to be adapted.

See also:MATCH

© 2014-2026,Andrey Gershun &Mathias Rangel Wulff

Please help improve the documentation by opening a PR on thewiki repo

Clone this wiki locally


[8]ページ先頭

©2009-2025 Movatter.jp