Essential cookies keep authentication working. With your permission, we also use analytics cookies to understand and improve the product. Read our Privacy Policy

DataEngPrep.tech
QuestionsPracticeAI CoachDashboardPricingBlog
ProLogin

Interview Questions

Real questions from top companies in SQL

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

How would you handle data type changes for an existing column?

SQLmediumwindow0.8 min read
Capco
β†’
122

How would you handle duplicate or corrupted data in a batch ETL job?

SQLmediumetlpartitionspark0.7 min read
Adidas
β†’
123

How would you handle null values in a dataset, especially in a single column?

SQLeasy0.7 min read
Infosys
β†’
124

How would you handle nulls in a SQL join? Provide examples using COALESCE.

SQLmediumjoinsql0.7 min read
Bristol Myers Squibb
β†’
125

How would you identify duplicate records based on a composite key in SQL?

SQLmediumpartitionsqlwindow0.8 min read
Amazon
β†’
126

How would you optimize a SQL query for better performance when working with large datasets?

SQLhardjoinoptimizationpartition0.7 min read
Tredence
β†’
127

How would you optimize a query fetching sales data across multiple countries with billions of rows?

SQLmediumbigquerypartitionsnowflake0.6 min read
Adidas
β†’
128

How would you optimize a query with multiple joins and subqueries?

SQLmediumjoin0.7 min read
American Express
β†’
129

How would you prevent small file problems in S3 when loading data into Redshift?

SQLmediumetlpartitionspark0.6 min read
Capco
β†’
130

How would you retrieve the first and last order for each customer from a sales table?

SQLmediumpartitionwindow0.7 min read
Wipro
β†’
131

Identify and remove duplicate records from a table, keeping the most recent record based on a timestamp column.

SQLmediumpartitionsparksql0.6 min read
Goldman Sachs
β†’
132

Identify consecutive numbers in a column (at least 3 consecutive).

SQLeasy0.7 min read
Incedo
β†’
133

If manual partitions are created in a Hive data-warehouse table directory, and you query records from those partitions, will you see the data? If not, how can this be fixed?

SQLmediumpartition0.6 min read
Dunnhumby
β†’
134

Implement a CASE WHEN condition - medium difficulty

SQLmedium0.7 min read
Wolters Kluwer
β†’
135

In Python, process a large CSV in chunks and remove duplicate records based on email and timestamp.

SQLhardpython0.5 min read
Amazon
β†’
136

Indexing - True/False question on indexes and query optimization

SQLhardjoinoptimization0.6 min read
Myntra
β†’
137

Kafka Basics - architecture, topics, partitions, producers, consumers, Zookeeper

SQLhardjoinoptimizationpartition3.6 min read
Lumiq
β†’
138

Kafka Partitioning: How would you ensure even load distribution across Kafka partitions in a high-volume system?

SQLmediumpartition0.5 min read
BCG
β†’
139

Merge two dictionaries and remove keys with null values.

SQLeasypython0.5 min read
BCG
β†’
140

SQL Query Design: employees with highest salaries within each department

SQLhardjoinoptimizationpartition3.6 min read
Walmart
β†’

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...5678910Next
Categories
All QuestionsSQLSpark / Big DataPython / CodingSystem DesignCloud / ToolsBehavioral
By Company
AmazonGoogleDatabricksSnowflakeAWSAzureMicrosoftNetflixUberTCS
Interview Guides
All GuidesTop SQL QuestionsTop Spark QuestionsPySpark QuestionsTop Python QuestionsTop System DesignKafka QuestionsAirflow QuestionsSQL Window FunctionsETL QuestionsData Modeling
Products
AI Interview CoachAnswer AnalyzerSQL PlaygroundResume AnalyzerAnswer Vault PDFsPricing
Company
About & Editorial PolicyContact UsAI DisclosureDisclaimerTerms of ServicePrivacy Policy
Β© 2026 DataEngPrep.tech. All rights reserved.
AboutBlogContactDisclaimer