https://github.com/suman105/leetcode-sql-50
LeetCode SQL 50 Solutions – A curated collection of optimized SQL solutions covering essential concepts like joins, aggregations, window functions, and subqueries.
https://github.com/suman105/leetcode-sql-50
sql
Last synced: 6 months ago
JSON representation
LeetCode SQL 50 Solutions – A curated collection of optimized SQL solutions covering essential concepts like joins, aggregations, window functions, and subqueries.
- Host: GitHub
- URL: https://github.com/suman105/leetcode-sql-50
- Owner: suman105
- Created: 2025-02-16T17:55:54.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-03-01T06:30:36.000Z (over 1 year ago)
- Last Synced: 2025-03-01T07:25:30.843Z (over 1 year ago)
- Topics: sql
- Homepage:
- Size: 14.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# **LeetCode SQL 50 - Solutions 🚀**
Welcome to my LeetCode SQL 50 solution repository! This repository contains well-structured, optimized SQL solutions for all LeetCode SQL 50 problems, along with detailed explanations to enhance your understanding.
## 📌 **About LeetCode 75**
**LeetCode SQL 50** is a curated list of essential SQL problems designed to improve database querying skills for technical interviews, data analytics, and software development. These problems cover a broad range of SQL concepts, including **Joins**, **Aggregate Functions**, **Subqueries**, and **String Functions**.
## 📂 **Repository Structure**
The solutions are categorized based on SQL topics for easy navigation:
- **Advanced Select and Joins**
- **Advanced String Functions / Regex / Clause**
- **Basic Aggregate Functions**
- **Basic Joins**
- **Select**
- **Sorting and Grouping**
- **Subqueries**
## 📑 LeetCode SQL 50 Problem List
I have solved all LeetCode SQL 50 problems, and they are organized based on their topics. You can find the solutions in their respective folders/files.
## 🔥 **Getting Started**
### Clone the Repository
To get a local copy, use the following command:
```sh
git clone https://github.com/suman105/LeetCode-SQL-50.git
cd LeetCode-SQL-50
```
## ⚙️ **Prerequisites**
Ensure you have **[MySQL](https://www.mysql.com/downloads/)** or **[PostgreSQL](https://www.postgresql.org/download/)** installed on your system. You can use any database management system that supports SQL.
## 🖥️ **Running the SQL Queries**
You can execute the queries in your preferred SQL environment (e.g., MySQL Workbench, PostgreSQL, SQLite, or an online SQL compiler).
- To run a SQL file using MySQL command line:
```sh
mysql -u your_username -p your_database < filename.sql
```
- For PostgreSQL:
```sh
psql -U your_username -d your_database -f filename.sql
```
## 🤝 **Contributions**
Contributions are welcome! Feel free to fork this repository, suggest improvements, or add alternative solutions. To contribute:
1. Fork the repository.
2. Create a new branch.
```sh
git checkout -b feature-branch
3. Commit your changes.
```sh
git commit -am 'Add new SQL solution'
4. Push to your fork.
```sh
git push origin feature-branch
5. Open a pull request.
## ⭐ **Show Some Support**
If you find this repository helpful, consider giving it a star ⭐ on GitHub. Your support motivates me to continue improving and adding more solutions! 🚀
Happy Querying! 🖥️📊