BootcampHackathonHiring ChallengeHiring DayAll Events
Employer
What is SQL? What Does It Do? SQL Commands and Examples

What is SQL? What Does It Do? SQL Commands and Examples

Learn from the experiences of Esra Ünlü, one of our Summer Camp participants. At Techcareer.net, we answer your tech questions with the Tech Talent's Code Diary.
Techcareer.net
Techcareer.net
09.08.2025
4 Minutes

SQL (Structured Query Language) is a widely used language designed to query and manage relational databases. It was created by IBM in the 1970s and has since become the primary language for popular systems such as MySQL, PostgreSQL, Oracle, and Microsoft SQL Server.

Today, we’ve stepped into the age of data; every click, like, and purchase generates a data point. To organize, manage, and extract meaningful insights from this massive ocean of data, SQL comes into play. In short, SQL is the magical tool that allows us to interact with databases.

The Main Purpose of SQL

The primary purpose of SQL is to store, organize, and analyze data. However, it doesn’t do this randomly; it manages data within a structure and logical framework.

Let’s think of it with a metaphor: The database is a library, tables are the shelves, and data is the books. SQL is your helpful librarian—it helps you find the book you want, add new ones, or update existing ones.

What is SQL Used For?

The main use cases of SQL can be summarized as follows:

  • Data Querying: Find and analyze records in a database.
  • Data Insertion: Add new records such as customers, products, or orders.
  • Data Updating: Modify existing records (e.g., update a product price).
  • Data Deletion: Remove data that is no longer needed.
  • Database Management: Create and modify tables, manage user permissions.
  • Reporting and Analysis: Generate quick reports from large datasets.

For example, in an e-commerce platform, SQL queries can easily answer questions such as “the total number of orders from customers in Istanbul” or “the best-selling products.”

SQL Commands

SQL commands are grouped according to their functions:

DDL (Data Definition Language): Defines the structure of a database.

  • CREATE → Creates a new table/database
  • ALTER → Modifies a table structure
  • DROP → Deletes a table/database

DML (Data Manipulation Language): Handles data operations.

  • SELECT → Queries data
  • INSERT → Adds data
  • UPDATE → Modifies data
  • DELETE → Removes data

DCL (Data Control Language): Manages user permissions.

  • GRANT → Grants permissions
  • REVOKE → Revokes permissions

TCL (Transaction Control Language): Controls transactions.

  • COMMIT → Saves transactions
  • ROLLBACK → Undoes transactions

SQL Data Types

Different SQL data types are used to store data correctly:

  • Numeric Types: INT, FLOAT, DECIMAL
  • Text Types: CHAR, VARCHAR, TEXT
  • Date/Time Types: DATE, TIME, DATETIME, TIMESTAMP
  • Logical Types: BOOLEAN

Examples:

  • A customer’s age → INT
  • Name → VARCHAR
  • Birthdate → DATE
  • Product price → DECIMAL

SQL Query Examples

1. Select Data (SELECT): List all customers:

SELECT * FROM Customers;


2. Conditional Query (WHERE): Find customers in Istanbul:

SELECT first_name, last_name FROM Customers WHERE city = 'Istanbul';


3. Insert Data (INSERT): Add a new customer:

INSERT INTO Customers (first_name, last_name, city)
VALUES ('Ayşe', 'Yılmaz', 'Ankara');


4. Update Data (UPDATE): Change a product price:

UPDATE Products SET price = 500 WHERE product_name = 'Copper Coffee Pot';


5. Delete Data (DELETE): Delete an order:

DELETE FROM Orders WHERE order_id = 10;

Learning SQL

Learning SQL is not as hard as you might think. With a bit of patience and regular practice, you can progress quickly.

The best part about SQL is that you can immediately apply what you learn. It’s not just theory; even with small commands, you can do amazing things in databases.

Examples:

  • Create a small table to track your coffee orders.
  • Store your movie list and query: “Show me the movies with IMDb ratings above 8.”
  • Build a mock customer table and practice inserting, deleting, and updating data.

A little tip: Adapt SQL to your real life. For example, create a table for your shopping list or manage your group’s FIFA tournament scoreboard with SQL. This way, you’ll not only have fun but also learn much faster.

Conclusion

SQL is one of the unseen heroes of the digital world. Bank transactions, e-commerce product catalogs, and social media user data are all managed thanks to SQL.

Knowing SQL is valuable not only for developers but also for marketers, data analysts, designers, and even entrepreneurs—because understanding and managing data has become essential in every profession.

When you start learning SQL, it’s perfectly normal to feel like a hacker when you first type SELECT * FROM. But remember, SQL is not just about writing code—it’s a way of managing, organizing, and drawing meaningful insights from data.

And the best part is, you don’t need a fancy computer, expensive courses, or years of waiting to learn it. With just a browser, some curiosity, and a few minutes of daily practice, you can step into the world of SQL.

In short:

  • Learning SQL is an investment in your future.
  • Start simple, practice often, and apply what you learn to everyday life.
  • And most importantly: Have fun while learning!
esra-unlu.png

More Stories

Techcareer.net AI Barometer: Türkiye’de Şirketlerin Yapay Zeka Hazırlık Düzeyini Ölçüyoruz

Techcareer.net AI Barometer: Türkiye’de Şirketlerin Yapay Zeka Hazırlık Düzeyini Ölçüyoruz

Yapay zeka (AI), iş dünyasında büyük bir dönüşüm yaratıyor, operasyonel süreçlerden müşteri deneyimine kadar birçok alanda değişim sağlıyor.
24.11.2025
2 Minutes
TECHCAREER
About Us
techcareer.net
Türkiye’nin teknoloji kariyeri platformu
SOCIAL MEDIA
LinkedinTwitterInstagramYoutubeFacebook

tr

en

All rights reserved
© Copyright 2025
support@techcareer.net
İşkur logo

Kariyer.net Elektronik Yayıncılık ve İletişim Hizmetleri A.Ş. Özel İstihdam Bürosu olarak 31/08/2024 – 30/08/2027 tarihleri arasında faaliyette bulunmak üzere, Türkiye İş Kurumu tarafından 26/07/2024 tarih ve 16398069 sayılı karar uyarınca 170 nolu belge ile faaliyet göstermektedir. 4904 sayılı kanun uyarınca iş arayanlardan ücret alınmayacak ve menfaat temin edilmeyecektir. Şikayetleriniz için aşağıdaki telefon numaralarına başvurabilirsiniz. Türkiye İş Kurumu İstanbul İl Müdürlüğü: 0212 249 29 87 Türkiye iş Kurumu İstanbul Çalışma ve İş Kurumu Ümraniye Hizmet Merkezi : 0216 523 90 26