DataEngPrep.tech
QuestionsPracticeAI CoachDashboardPacksBlog
ProLogin

Interview Questions

Real questions from top companies in SQL Β· medium

700+ Easy450+ Medium650+ Hard
All CategoriesBehavioralSpark/Big DataSQLPython/CodingSystem Design/ArchitectureCloud/ToolsGeneral/Othereasymediumhard
81

Explain row_number, rank, and dense_rank with examples.

SQLmediumpartition0.3 min read
Fractal
β†’
82

Explain the difference between a clustered and non-clustered index.

SQLmediumjoinsql0.3 min read
Gartner
β†’
83

Explain the difference between a fact table and a dimension table.

SQLmediumjoin0.3 min read
Gartner
β†’
84

Explain the difference between a primary key and a unique key.

SQLmediumjoinsql0.3 min read
Gartner
β†’
85

Explain the concept of window functions in SQL and provide an example

SQLmediumjoinpartitionsql0.6 min read
McKinsey
β†’
86

Explain the difference between Star and Snowflake schemas. When would you choose one over the other?

SQLmediumjoinsnowflakesql0.6 min read
BCG
β†’
87

Explain the difference between partition count and query performance in Spark.

SQLmediumpartitionspark0.5 min read
Incedo
β†’
88

Explain the differences between table re-creation and ALTER TABLE operations.

SQLmediumpartition0.5 min read
Capco
β†’
89

Explain the order in which SQL clauses are executed.

SQLmediumjoinsql0.4 min read
Fossil Group
β†’
90

Explain the process you would follow for optimizing a database query that is running slow.

SQLmediumjoinpartitionwindow0.5 min read
Amazon
β†’
91

Explain the use of surrogate keys vs. natural keys in data modeling.

SQLmediumjoin0.4 min read
BCG
β†’
92

Explain types of joins in Spark with examples.

SQLmediumjoinspark0.4 min read
Freecharge
β†’
93

Explain your approach to optimizing a slow-running query on a table with billions of rows.

SQLmediumpartition0.3 min read
Goldman Sachs
β†’
94

Explain your understanding of indexing, partitioning, and execution plans.

SQLmediumjoinpartition0.4 min read
Apple
β†’
95

Fact vs Dimension Table - categorize data

SQLmediumjoinpartition0.3 min read
Myntra
β†’
96

Facts and Dimension Tables Properties

SQLmediumpartition0.3 min read
Nagarro
β†’
97

Filter Rows Where Employee Salary > Manager Salary

SQLmediumjoin0.3 min read
LTIMindtree
β†’
98

Find 3rd Highest Salary

SQLmedium0.3 min read
LTIMindtree
β†’
99

Find Employees with Maximum Salary in Each Department

SQLmediumpartitionwindow0.3 min read
TCS
β†’
100

Find average salary by department, max average salary, and list of employees for the max salary department.

SQLmedium0.3 min read
Gartner
β†’

Reading isn't practice. Get AI feedback on your answers.

Type or paste your answer to any of these questions and our AI Coach scores it, highlights gaps, and rewrites it at FAANG quality. Free to try.

Try AI Answer Coach β€” FreeStart a Mock Interview
Previous1...34567...14Next
Categories
All QuestionsSQLSpark / Big DataPython / CodingSystem DesignCloud / ToolsBehavioral
By Company
AmazonGoogleDatabricksSnowflakeMicrosoftNetflixUberTCS
Interview Guides
All GuidesTop SQL QuestionsTop Spark QuestionsTop Python QuestionsTop System DesignSQL Window FunctionsETL QuestionsData Modeling
Products
AI Interview CoachAnswer AnalyzerSQL PlaygroundResume AnalyzerInterview PacksPricing
Company
About UsContact UsAI DisclosureDisclaimerTerms of ServicePrivacy Policy
Β© 2026 DataEngPrep.tech. All rights reserved.
AboutBlogContactDisclaimer