Course: CSCI 2020

Part A

  • Since Part A was mainly just to generate data, I used my resources (ChatGPT) to generate most of the data, and then I went back and changed a few things that were incorrect.
  • I donā€™t see much ā€˜helpfulnessā€™ of creating the data myself, since itā€™s a largely menial task which will produce pretty similar results of just asking ChatGPT to generate data. I had to also go back and ensure that the data was ā€˜realisticā€™, so I made sure to double check everything.

Part B

Part 1

  • For the analysis, it was pretty straightforward. The only thing I needed to ensure was that the species was not null, since there were certain sales items in which it was for products, rather than pets (so I did a JOIN rather than a LEFT JOIN). Interestingly, there are ā€˜duplicate speciesā€™, but thatā€™s just due to different sale locations for each speciesā€”since you can purchase species at different locations.

Part 2

  • This analysis was pretty straightforward as well; I just utilized the COUNT, SUM, and AVG functions with data from Products table. The category habitat has the most total. Also, I added a out_of_stock column, which indicates the number of products that are out of stock within that certain category.

Part 3

  • This was pretty simple, I just did the number of total purchases (with the COUNT). Also, I added the total spent and the average purchase for each planet. Interestingly, Earth is the planet with the highest total spent, although it has the second highest average purchase.

Part C

Part 1

  • For this, it was pretty simple to get the actual data. However, to extract the actual ā€˜monthā€™, formatted nicely, I used the FORMAT function, with MMMM as the second argument to display the entire month name.

Part 2

  • This one was pretty simple as well, I just got the total transactions, the total revenue, and the average transaction for each payment method. The highest average transaction is credit, followed by cash, and then debit.

Part 3

  • This is pretty similar to another part within this lab. I did a few functions, such as SUM, AVG, and COUNT. The species that has the highest revenue is the Canine species, followed by Aquatic, and then Avian. As for the popularity, I just thought that it would be the total sales volumeā€”since I wasnā€™t sure how else the popularity would be ranked, unless there was a rating between 0 and 10, but I wasnā€™t sure how that would be implemented, unless you had a complex fucntion.