Skip to content

AldythNahak/leetcode_mssql_solution

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

17 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

LeetCode SQL Solutions – MS SQL Server πŸ—ƒοΈ

This repository contains my solutions to LeetCode SQL problems, written and tested using Microsoft SQL Server.

🧠 About

Each solution focuses on:

  • Correctness – aligned with LeetCode’s expected results
  • Readability – clear SQL formatting and naming
  • Performance – where applicable, optimized with proper joins, indexing logic, or CTEs

πŸ“ Folder Structure

leetcode_mssql_solution/ β”œβ”€β”€ easy/ β”œβ”€β”€ medium/ β”œβ”€β”€ hard/ └── README.md


βš™οΈ Tested On

  • SQL Engine: Microsoft SQL Server 2019+
  • Environment: SQL Server Management Studio (SSMS), Azure Data Studio, or online emulators

πŸ“Œ Note

Some LeetCode problems may use MySQL syntax. When needed, I adapt them to valid T-SQL for MS SQL Server, using equivalents like:

  • LIMIT β†’ TOP, OFFSET FETCH
  • Date functions: GETDATE(), DATEDIFF(), FORMAT()
  • String functions: CHARINDEX, LEFT, RIGHT, etc.

πŸ§‘β€πŸ’» Author

Aldyth Nahak
GitHub | LinkedIn


⭐️ Contributions

Feel free to fork, star, or suggest improvements!

πŸ’° You can help me by Donating

BuyMeACoffee PayPal

About

A collection of solutions to LeetCode database problems using Microsoft SQL Server (T-SQL). Includes optimized queries with clear logic and comments. Great for practicing SQL Server-specific syntax, improving database querying skills, and preparing for SQL interviews focused on T-SQL

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages