Sql Ppt Portfolio

1,144 views

Published on

SQL Server Projects

Published in: Technology, Education
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
1,144
On SlideShare
0
From Embeds
0
Number of Embeds
21
Actions
Shares
0
Downloads
31
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Sql Ppt Portfolio

  1. 1. <ul><li>.SQL Portfolio </li></ul><ul><li>Name: Stephen Slaven </li></ul><ul><li>Email : sslaven50@yahoo.com </li></ul><ul><li>Phone: (407)-287-9984 </li></ul><ul><li>Cell Phone: (856)-340-2766 </li></ul>2/19/2009
  2. 2. Table of Contents <ul><li>Library Client Application </li></ul><ul><li>PiggyBank Project </li></ul><ul><li>Library Report Project </li></ul><ul><li>BlockFlix Movie Project </li></ul>2/19/2009 [email_address]
  3. 3. Library Client application <ul><li>Library Database </li></ul><ul><li>Return member info from Member and Adult table </li></ul><ul><li>Display available books </li></ul><ul><li>Search member info using member number </li></ul><ul><li>Use UNION, list all member reserve the specific book </li></ul><ul><li>Use CASE, list all member reserve the specific book </li></ul><ul><li>Create temporary table </li></ul><ul><li>Display members have past due loan use temporary table </li></ul><ul><li>Display members who pay highest fine </li></ul><ul><li>List of member who want to reserve the specific book </li></ul>2/19/2009 [email_address]
  4. 4. Library Diagram 2/19/2009
  5. 5. Display available books 2/19/2009
  6. 6. Use UNION 2/19/2009
  7. 7. Display member pay highest fine 2/19/2009
  8. 8. Library Stored Procedure <ul><li>Add </li></ul><ul><li>Add </li></ul><ul><li>Check </li></ul><ul><li>Check </li></ul><ul><li>Add </li></ul><ul><li>Convert </li></ul><ul><li>Renew </li></ul><ul><li>Update </li></ul>2/19/2009
  9. 9. ADD ADULT Stored procedure 2/19/2009
  10. 10. CHECK OUT ITEM Stored Procedure 2/19/2009
  11. 11. WORKING TEST SCRIPT 2/19/2009
  12. 12. Create PiggyBank Database 2/19/2009
  13. 13. <ul><li>DDL - Prevent Drops/Alters to Tables & Views </li></ul><ul><li>DML – Prevent Deletes on Adult Table </li></ul>PiggyBank Triggers 2/19/2009
  14. 14. DDL Trigger 2/19/2009
  15. 15. DML Trigger 2/19/2009
  16. 16. <ul><li>Add Account </li></ul><ul><li>Add Customer </li></ul><ul><li>Deposits </li></ul><ul><li>Check Balance </li></ul><ul><li>Transactions </li></ul><ul><li>Update Interest Rates </li></ul><ul><li>Search by Customer </li></ul><ul><li>Withdrawals </li></ul>PiggyBank Stored Procedure 2/19/2009
  17. 17. Add Account Stored Procedure 2/19/2009
  18. 18. Add Customer Stored Procedure 2/19/2009
  19. 19. Deposits Stored Procedure 2/19/2009
  20. 20. Get Balance Stored Procedure 2/19/2009
  21. 21. Transactions Stored Procedure 2/19/2009
  22. 22. Update Interest Rates Stored Procedure 2/19/2009
  23. 23. Search by Customer Name 2/19/2009
  24. 24. Withdrawals Stored Procedure 2/19/2009
  25. 25. <ul><li>Complete List of Books </li></ul><ul><li>Most Active Members for a month </li></ul><ul><li>Kids Reading Club </li></ul><ul><li>Current Fines Report </li></ul><ul><li>Total Fines by Member </li></ul>Reports for Library Project 2/19/2009
  26. 26. Complete List of Books 2/19/2009
  27. 27. Most Active Members for Month 2/19/2009
  28. 28. Kids Reading Club Report 2/19/2009
  29. 29. Current Fines Report 2/19/2009
  30. 30. Total Fines by Member 2/19/2009
  31. 31. BlockFlix Project 2/19/2009
  32. 32. BlockFlix ERD Diagram 2/19/2009
  33. 33. High Availability <ul><li>Corporate headquarters : </li></ul><ul><li>Principal server in Omaha, NE </li></ul><ul><li>Mirror server in Kansas City, KS </li></ul><ul><li>Witness server in Helena, MT </li></ul><ul><li>Regional Servers: </li></ul><ul><li>Western United States: </li></ul><ul><li>Principal Server - Flagstaff, AZ </li></ul><ul><li>Mirror Server - Las Vegas, NV </li></ul><ul><li>Witness Server - San Antonio, TX </li></ul><ul><li>Eastern United States: </li></ul><ul><li>Principal Server – Atlanta, GA </li></ul><ul><li>Mirror Server – Memphis, TN </li></ul><ul><li>Witness Server – Indianapolis, IN </li></ul>2/19/2009
  34. 34. <ul><li>Corporate </li></ul><ul><li>Will have a (32-bit) requirement: </li></ul><ul><ul><li>1. Server: Windows Small Business Server 2003 Premium Edition SP1 </li></ul></ul><ul><ul><li>2. There will be 3 servers: 1 Production, 1 Backup, and 1 Witness </li></ul></ul><ul><ul><li>3. SQL Server 2005 Enterprise Edition </li></ul></ul><ul><ul><li>4. Pentium III – compatible processor with 1 GHz processor speed </li></ul></ul><ul><ul><li>5. Memory – 2 GB </li></ul></ul><ul><ul><li>6. Disk Space: 400 GB for Production and Backup and 100 GB for Witness </li></ul></ul>Hardware Considerations 2/19/2009
  35. 35. <ul><li>Regional Stores </li></ul><ul><li>Will have a (32-bit) requirement: </li></ul><ul><ul><li>1. Server: Windows Small Business Server 2003 Premium Edition SP1 </li></ul></ul><ul><ul><li>2. There will be 3 servers: 1 Production, 1 Backup, and 1 Witness </li></ul></ul><ul><ul><li>3. SQL Server 2005 Standard Edition </li></ul></ul><ul><ul><li>4. Pentium III – compatible processor with 1 GHz processor speed </li></ul></ul><ul><ul><li>5. Memory – 1 GB </li></ul></ul><ul><ul><li>6. Disk Space: 200 GB for Production and Backup and 100 GB for Witness </li></ul></ul>Hardware Considerations (cont.) 2/19/2009
  36. 36. <ul><li>Regular Stores </li></ul><ul><li>Will have a (32-bit) requirement: </li></ul><ul><li>1. Server: Windows Small Business Server 2003 Premium Edition SP1 </li></ul><ul><li>2. SQL Server 2005 Standard Edition </li></ul><ul><li>3. Pentium III – compatible processor with 1 GHz processor speed </li></ul><ul><li>4. Memory – 1 GB </li></ul><ul><li>5. Disk Space: 200 GB </li></ul>Hardware Considerations (cont.) 2/19/2009
  37. 37. <ul><li>BlockFlix will be using Redgate’s SQL Backup 3 rd party software. SQL Backup will provide the following benefits: </li></ul><ul><ul><li>1. Compression of backup files up to 90% - saving on backup space </li></ul></ul><ul><ul><li>2. Using 256-bit AES encryption will create secure backup </li></ul></ul><ul><li>NOTE: We will use this software, until SQL Server 2008 is implemented. When SQL Server will have its own backup encryption. We will at that time evaluate both and determine which is a better backup solution. </li></ul><ul><li>Retention of the daily tapes will be Monthly. </li></ul><ul><li>Retention of the Monthly tapes will be 7 years. </li></ul><ul><li>Retention of Yearly backup will be indefinite. </li></ul>Backup Strategy 2/19/2009
  38. 38. Maintenance Plan 2/19/2009 Task Time Daily/Weekly Backup DB Differential Every hour Daily Check Database Integrity 22:00 Daily Shrink Database 22:30 Daily Reorganize Indexes 23:00 Daily Rebuild Indexes 0:00 Weekly – Sunday Update Statistics 1:00 Weekly - Sunday Cleanup History 2:00 Weekly - Sunday Backup BlockFlix and system DBs 3:00 Weekly - Sunday Backup Transaction Log 5:00 Daily Maintenance Cleanup 6:00 Weekly - Sunday
  39. 39. Daily Maintenance Plan Diagram 2/19/2009
  40. 40. Weekly Maintenance Plan Diagram 2/19/2009
  41. 41. Maintenance Plan Email 2/19/2009
  42. 42. <ul><li>BlockFlix will need to address the retention of the data long term. We will have backups, but we need the data to be available at all times. </li></ul><ul><ul><ul><li>1. We will partition the following tables: </li></ul></ul></ul><ul><ul><ul><ul><li>A. Inventory </li></ul></ul></ul></ul><ul><ul><ul><ul><li>B. Transactions </li></ul></ul></ul></ul><ul><ul><ul><ul><li>C. Customer </li></ul></ul></ul></ul><ul><ul><ul><ul><li>D. Movie </li></ul></ul></ul></ul><ul><ul><ul><ul><li>E. Rental </li></ul></ul></ul></ul><ul><ul><ul><li>2. We will strip off data from the tables that are over 1 year old and send the data to the backup server. </li></ul></ul></ul>Archival Plan 2/19/2009
  43. 43. <ul><li>Usp_AddStore Results </li></ul>Stored Procedures 2/19/2009
  44. 44. <ul><li>usp_CheckedOutMovies Results </li></ul>Stored Procedures (cont.) 2/19/2009
  45. 45. <ul><li>usp_InactiveAccounts Results </li></ul>Stored Procedures (cont) 2/19/2009
  46. 46. <ul><li>usp_LostDamaged Results </li></ul>Stored Procedures (cont.) 2/19/2009
  47. 47. <ul><li>usp_Payments Results </li></ul>Stored Procedures (cont.) 2/19/2009
  48. 48. Function – ufn_GetLastDayOfMonth 2/19/2009
  49. 49. <ul><li>Add triggers to prevent inserts, </li></ul><ul><li>deletes, or updates to tables: </li></ul><ul><li>Inventory </li></ul><ul><li>Movie </li></ul><ul><li>Rental </li></ul><ul><li>Store </li></ul><ul><li>Transactions </li></ul><ul><li>Talent </li></ul><ul><li>Prevent alters or drops on BlockFlix </li></ul><ul><li>tables and views </li></ul>Triggers 2/19/2009
  50. 50. <ul><li>Prevent Store Insert Prevent Store Update </li></ul>Triggers (cont.) 2/19/2009
  51. 51. <ul><li>Prevent Inventory Delete Prevent Movie Delete </li></ul>Triggers (cont.) 2/19/2009
  52. 52. <ul><li>BlockFlix purchases movies in bulk through the corporate headquarters and distributes them to the stores.  The package of movies includes an XML File that contains a list of movies.  The XML file will be run by the store to update the following their inventory tables: </li></ul><ul><li>-          Movie </li></ul><ul><li>-          MovieTalent </li></ul><ul><li>-          Inventory </li></ul><ul><li>A separate feed from corporate will have already loaded tables: </li></ul><ul><li>-          Talent Type (actors, directors and producers) </li></ul><ul><li>-          Talent </li></ul><ul><li>-          RatingType  (G, PG, PG-13, R, NC-17) </li></ul><ul><li>-          Genre (Action, Drama, Chick Flick, Horror, etc) </li></ul><ul><li>-          Store </li></ul>XML 2/19/2009
  53. 53. Demo of XML File 2/19/2009
  54. 54. Movie Checkout 2/19/2009
  55. 55. Reports 2/19/2009
  56. 56. Reports (cont.) 2/19/2009
  57. 57. Reports (cont.) 2/19/2009
  58. 58. Reports (cont.) 2/19/2009
  59. 59. <ul><li>Logins will be assigned using Windows and SQL Server authentication </li></ul><ul><li>Roles will be assigned according to user groups specific to their job tasks </li></ul><ul><li>Permissions will be set according to their user groups </li></ul><ul><li>Corporate leaders and store managers will have access to all servers </li></ul><ul><li>Employees within corporate such as marketing representatives will have access only to stored procedures with the necessary privileges to the tables needed to run their reports </li></ul><ul><li>Store level employees will be denied changes to the tables and only granted select permissions on tables where necessary to run the stored procedures </li></ul>Users/Logins/Permissions 2/19/2009
  60. 60. <ul><ul><li>through Stored Procedures </li></ul></ul><ul><ul><li>Prevent SQL Injection attacks </li></ul></ul><ul><ul><li>Grant most granular permission schema </li></ul></ul><ul><ul><li>Microsoft Baseline Security Analyzer </li></ul></ul><ul><ul><li>SQL Server Profiler </li></ul></ul><ul><ul><li>Maintain Updated Hotfixes or Service Packs </li></ul></ul>Application Security 2/19/2009
  61. 61. Certificates/Encryption 2/19/2009
  62. 62. Certificates/Encryption(cont.) 2/19/2009
  63. 63. Video Streaming 2/19/2009

×