PGoCareerGoCareer prep tools
LoginSign up
  • Java
  • Python
  • AI
  • React
  • Angular
  • PHP
  • Node.js
  • SQL
  • DSA
  • HTML
  • CSS
  • JS
  • Spring
  • ML
  • MongoDB

SQL · Theory

Not Like Operator

← All stacks

Theory

105/439

Not Like Operator

Not Like Operator is pattern matching. LIKE uses % and _. REGEXP / RLIKE uses regular expressions (e.g. name REGEXP '^[A-Z]'). They are not interchangeable.

REGEXP_LIKE, REGEXP_REPLACE, REGEXP_SUBSTR, REGEXP_INSTR are MySQL 8 helpers. Don’t write Java-style /pattern/g.

Trap — LIKE with regex stars. Trap: REGEXP on a huge unindexed column.

On the example next to this theory — Not Like Operator — wHERE combines predicates with AND/OR; LIKE does pattern match.

Exam tip

LIKE vs REGEXP in one sentence, plus one example.

Not Like Operator — sample query

CREATE TABLE products (id INTEGER PRIMARY KEY, name TEXT, price REAL);
INSERT INTO products VALUES (1, 'Pen', 10), (2, 'Book', 200), (3, 'Bag', 50);
SELECT * FROM products
WHERE price BETWEEN 20 AND 150 AND name LIKE 'B%';

Not Like Operator — wHERE combines predicates with AND/OR; LIKE does pattern match.

Short notes

  • DefNot Like Operator matches text by a pattern.
  • RuleLIKE = % _. REGEXP = regular expressions.
  • TrapMixing LIKE wildcards with regex.

Questions

1

LIKE vs REGEXP?

105 / 439

P

GoCareerGo

Utilities · Preparation Hub · Resume · CV · Tools — one workspace.

Workspace

DashboardProfilePreparation HubResume builderCV builderCareer planning

PDF Tools

Merge PDFSplit PDFCompress PDFImage to PDFAll toolsJobs

Image & QR

Compress ImageResize ImageQR ScannerQR GeneratorBlogIT interview prep

Company

FAQFeedbackContactPrivacyTermsSitemap

© 2026 GoCareerGo. Keep moving forward.