de_notes

📚 TRIM

The TRIM function is used in SQL to remove unwanted spaces (or other characters) from the beginning and end of a string.
It is helpful for cleaning up messy or inconsistent data.


🛠️ Basic Syntax

SELECT TRIM(column_name)
FROM table_name;

Example

SELECT TRIM(first_name) AS cleaned_first_name
FROM employees;

Key Points

Additional Example

SELECT TRIM('   Hello World   ') AS trimmed_text;

🎥 Video Notes


📝 Problem Description

Describe the problem, challenge, or topic discussed in a video related to SELECT FROM.
What concept was explained or what exercise was solved?


DataBase Given


💻 My SQL Code

-- Write your SQL code attempt or solution related to SQL COMMAND
SQL COMMAND

🧠 Solution Code / Explanation

SQL COMMAND

Explanation - Explain what you learned, any key takeaways, or how you solved the problem related to COMMAND._


⬅️ Previous: CHARINDEX or SUBSTRING_INDEX Next ➡️ LEFT & RIGHT