CodShot
SQL Public

Search Multiple Columns

Search several text columns with LIKE placeholders.

#sql #search #like #prepared-statements
SQL
SELECT id, title, description
FROM snippets
WHERE title LIKE :search_title
   OR description LIKE :search_description
   OR language_code LIKE :search_language
ORDER BY updated_at DESC;

Notes

Use prepared statements. Do not concatenate raw user input into SQL strings.

Snippet actions

CodShot user
CodShot user
Updated: 2026-06-03 15:31
Public snippets
0
Forks
CodShot AI Help
Ask about CodShot features, plans, workspace, AI limits, referrals, and public help topics.
Hi! I can help you understand how CodShot works. What would you like to know?
For account-specific or sensitive issues, please open a support ticket. Open support