Bing Zheng SQL Portfolio

31
SQL Portfolio Bing Zheng Email: [email protected] Phone: 646-709-4371

Transcript of Bing Zheng SQL Portfolio

Page 1: Bing Zheng SQL Portfolio

SQL Portfolio

Bing Zheng

Email: [email protected]

Phone: 646-709-4371

Page 2: Bing Zheng SQL Portfolio

Table of Contents

• JungleBooks• Library• Bank Project• SSIS/SSRS Project• BlockFlix

Page 3: Bing Zheng SQL Portfolio

JungleBooks• JungleBooks is a book company which has a database consisting of books,

authors, orders, and customers.

• In this project a database diagram is given and a database is created according to the diagram.

• We are asked to create multiple queries for different forms of the application the client is building.

Page 4: Bing Zheng SQL Portfolio

JungleBooks Database Diagram

Page 5: Bing Zheng SQL Portfolio

Large Orders Page from JungleBooks

Page 6: Bing Zheng SQL Portfolio

Expired Cards page from JungleBooks

Page 7: Bing Zheng SQL Portfolio

Hot Items page from JungleBooks

Page 8: Bing Zheng SQL Portfolio

Library• The Library Database is created to support the principle functions of a

lending library’s day-to-day operations.

• In this project a database diagram is given and a database is created according to the diagram.

• We are asked to create multiple queries for different forms of the application the client is building.

Page 9: Bing Zheng SQL Portfolio

Library Database Diagram

Page 10: Bing Zheng SQL Portfolio

Sample Library Query 1

Page 11: Bing Zheng SQL Portfolio

Sample Library Query 2

Page 12: Bing Zheng SQL Portfolio

Sample Library Query 3

Page 13: Bing Zheng SQL Portfolio

Bank Project: PiggyBank• The PiggyBank Database simulates bank operations such as OverDraft

Accounts, Customer and Account Relationships, and Transactions.

• Create an Entity Relationship Diagram given some specifications such as Overdraft Fees, Error Information when a transaction fails, Login Failures, and Customer/Account relationships.

Page 14: Bing Zheng SQL Portfolio

PiggyBank Database Diagram

Page 15: Bing Zheng SQL Portfolio

PiggyBank Add Account Stored Procedure

Page 16: Bing Zheng SQL Portfolio

PiggyBank Add Account Stored Procedure Cont.

Page 17: Bing Zheng SQL Portfolio

PiggyBank Account Deposit Stored Procedure

Page 18: Bing Zheng SQL Portfolio

SSIS/SSRS Project• For the SSIS (SQL Server Integration Services) portion, we created 6

packages in SQL Server Business Intelligence Development Studio. One package to create the database, four packages to import data from CSV files, and one to update the data.

– For the create database and update data, we just used an Execute SQL task in the Control Flow, while the others to import data we needed various tasks in the Data Flow.

• For the SSRS (SQL Server Reporting Services) portion, we created two reports: One was a sales matrix by year and the other was the top sales. We would also schedule report snapshots and subscriptions.

Page 19: Bing Zheng SQL Portfolio

SSIS – Data Flow for Importing Products Package

Page 20: Bing Zheng SQL Portfolio

SSIS – Control Flow for Importing Orders Package

Page 21: Bing Zheng SQL Portfolio

SSRS – Data Flows for Importing Orders Package

Page 22: Bing Zheng SQL Portfolio

SSRS – Sales Matrix By Year ReportIn this report there is a dropdown list of shipping methods the user can choose from.As displayed in the report, all the methods are selected.

Page 23: Bing Zheng SQL Portfolio

SSRS – Sales Matrix By Year ReportIn this report the user can set the parameters of the start and end dates along with which number of top products and vendors you want. As displayed the dates are set to 4/20/1995 and 4/20/2011 with top 5 for both product and vendors.

Page 24: Bing Zheng SQL Portfolio

BlockFlix• BlockFlix is our Final Group Project and it implemented almost all that I

have experienced in the program. A presentation was conducted by the group upon graduation.

• Some of the specification for this project included:– The database will be used to track inventory of movies, customers and their membership

types, and payments by customers.– Demo of inserting an XML file containing new releases into the database showing Title,

Genre, Rating, actors, producers, etc.– Each store has an individual database to keep track of local sales information which will

be uploaded to the central database.– Create reports for upper management and marketing department for lost/damaged

movies, most rented movies, most active customers, list of customers in each membership type, etc.

– Propose how to implement streaming online video rentals– Maintenance, Security, Backup, etc.

Page 25: Bing Zheng SQL Portfolio

BlockFlix – Database Diagram

Page 26: Bing Zheng SQL Portfolio

BlockFlix – XML FileThis is the XML File format used to load new movies into the database via SSIS.

Page 27: Bing Zheng SQL Portfolio

BlockFlix – Report Customers in each Membership Type

Page 28: Bing Zheng SQL Portfolio

BlockFlix – Report of Most Active Customers

Page 29: Bing Zheng SQL Portfolio

BlockFlix – Report of Lost/Damaged Movies

Page 30: Bing Zheng SQL Portfolio

BlockFlix – Video Streaming

• Archived Live Video OnDemand

• On demand avoids thin viewing stream due to the ‘stampede’ effect (everyone trying to view at once). This in turn reduces the need for heavy bandwidth and allows other resources to continue at standard expected levels.

Page 31: Bing Zheng SQL Portfolio

BlockFlix – Backup and Maintenance

• Transaction log backup will occur daily at midnight across servers for all databases.

• A full database backup is also scheduled on every Sunday at midnight for all databases

• Filegroups exist for transactions, movies, and for customer and disk inventory.

• Each filegroup exist on its own terrabyte disk