Solving SQL Interview Query | Ungroup given input data

In this video, we will solve an SQL Interview query which was asked during a interview by a FAANG company. The problem statement is to ungroup the given input data.

We need to write a query to split the given input data into multiple records as per the expected output.

To solve this problem, I will be using recursive SQL query. I will solve it in PostgreSQL but similar solution will also work in all the major RDBMS such as MySQL, MSSQL and Oracle.

All the scripts, dataset, sql queries (solution to this problem in PostgreSQL, Oracle, MySQL and Microsoft SQL Server) can be downloaded from below link:

Previous
Previous

Practice SQL Interview Query | Big 4 Interview Question

Next
Next

How to remove Duplicate Data in SQL