Skip to content

Sure5991/SQL-case-study---Paintings

Repository files navigation

SQL-case-study: Famous Paintings and Museums

To upload CSV files using Python in the paintings database and answer the queries of the Paintings Dataset case study using SQL

  1. artist.csv ( 9 columns, 421 rows )
  2. canvas_size.csv ( 4 columns, 200 rows )
  3. image_link.csv ( 4 columns, 14775 rows )
  4. museum.csv ( 9 columns, 57 rows )
  5. museum_hours.csv ( 4 columns, 350 rows )
  6. product_size.csv ( 4 columns, 109660 rows )
  7. subject.csv ( 2 columns, 6712 rows )
  8. work.csv ( 5 columns, 14716 rows )

1. Uploaded Painting CSV Files to Database Paintings ( Python )

  1. Created connection to database paintings using SQLAlchemy module
  2. Importing CSV files in the folder to Python using Pandas and OS module
  3. Converting Data into tables in the database using Pandas

2. Case Study of Painting Dataset using SQL

Questions were solved using complex SQL queries like

  1. CTEs
  2. Created User- Defined Function to extract time from String which was not available in Convert or Cast
  3. SubQueries
  4. Window Function like Row_number() and Rank() using Partition by or Order by
  5. Joins
  6. Date and Time Function
  7. Pattern Analysis function - PATINDEX
  8. String Function - Substring, Charindex and String_agg

About

Case Study of Painting to answer the queries using SQL

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published