Title | CS669 Term Project Iteration 1 |
---|---|
Author | april hus |
Course | Database Design and implementation for Business |
Institution | Boston University |
Pages | 10 |
File Size | 312.6 KB |
File Type | |
Total Downloads | 98 |
Total Views | 142 |
Download CS669 Term Project Iteration 1 PDF
MET CS 669 Database Design and Implementation for Business Term Project Iteration 1
TableofContents ProjectIntroduction.......................................................................................................................................2 WhatIsADatabaseUsedFor?.......................................................................................................................2 WhatYouWillBeCreating.............................................................................................................................3 ProjectDirectionOverview............................................................................................................................5 TrackMyBuysProjectDirectionOverview.................................................................................................5 UseCasesandFields......................................................................................................................................6 TrackMyBuysUseCasesandFields............................................................................................................6 SummaryandReflection................................................................................................................................8 TrackMyBuysSummaryandReflection.....................................................................................................8 ItemstoSubmit..............................................................................................................................................9 Evaluation....................................................................................................................................................10
Page1of10 Copyright2018‐2019BostonUniversity.AllRightsReserved.
Project Introduction Canyoudesign,implement,andstartusingyourveryowndatabase,allinonecourseterm?Youcan, evenifyouhavenevertouchedadatabaseinyourlife!Thetheoreticalconceptsandappliedskillsyou learnthroughoutthecourseprepareyouwellforthistask,andhavebeencarefullycraftedand sequencedforrapidlearning.Further,theteachingteamstandsreadytohelpfillanygaps,soyouare notdependentonthecoursematerialsalone.Youwillundoubtedlyputinmanyhoursofhardworkon thisproject,butyouwillleavethecoursewithyourowndatabase,andmoreimportantly,theskillsto buildotherones. Thestart‐to‐finishexperienceyougainfromthisprojectwillhelpprepareyoufordatabaseworkinthe industryoracademia.Ifyourbossasksyoutodevelopadatabase,you’llknowhowandhavethe experiencetobackupyourconfidence.Ifyoudecidetopursuedatabaseresearch,you’llhaveasolid foundation.Takethisprojecttoheart.Itwillpayoff! Theremainderofthisdocumentprovidesyouimportantdetailsongettingstartedwithyourproject.For thisfirstiteration,youwilldecidewhatkindofdatayouwanttocaptureinyourdatabaseandprovide anoverviewofyourproject.Readthroughthisdocumentcarefullyandasktheteachingteamif somethingisunclear.Youwillbespendingalotoftimedesigning,implementing,andtestingadatabase forthisproject.
What Is A Database Used For? Beforeyoucreateyourowndatabase,weneedtoaddressanobviousquestion:whatisadatabaseused for?Mostareawarethatorganizationsusedatabasestostoredatalongterm,butmaynotbeaware thatdatabasesalsoprovidethecriticalfeaturesofdatasecurityandefficientaccess.Databasesensure thatonlyauthorizedpeoplecanmakeuseofthedata,typicallywithextensiveandcustomizabledata securityconfigurations.Databasesalsoensurethatjusttherightdataitemscanberetrievedquickly (typicallyinlessthanasecond)fromamongstapotentiallyvastamountofstorage.Thissetsdatabases apartfromfile‐baseddatastorage. Thenextimportantquestionis,who,orwhat,accessesthedatabaseinanorganization?Broadly,a databaseisaccessedeitherbyI.T.professionalsorbyapplications.I.T.professionals,suchasdatabase administrators,databasedevelopers,dataanalysts,andthelike,accessthedatabasetoprogramit, administerit,ortomoredirectlyworkwiththedataitcontainsthroughuseofbusinessintelligence tools.Suchpeoplehavemoreintimateaccesstothedatabaseandusuallyhaveahigherleveloftrust withintheorganization.Everyoneelsegetsaccesstothedataindirectlythroughanapplication.The applicationdirectlyinteractswiththedatabase,andtheendusersusetheapplication.Whetheryou realizeitornot,youregularlyuseapplicationsthathaveadatabasebackend,betheyweb‐basedor otherwise.Forexample,ifyouuseAmazon.com,Ebay.com,andStudentLinkatBostonUniversity,,you areusingawebapplicationthathasadatabasebackend.Youdirectlyinteractwiththewebapplication, andtheapplicationinteractswiththedatabase. Whydoesthismattertoyou?Whenyou’redesigningyourdatabase,youneedtokeepinmindwhoor whatwillusethedatabaseandhowitwillbeused.Willitbeforpersonaluse?Foraclub?Foryourplace ofemployment?Foramobileapplication?Foranexistingreal‐worldbusiness(suchasAmazonorEbay)? Onlyyoucananswerthewho,what,andhowforyourdatabase.Adatabaseisnotdesignedina vacuum;rather,itisdesignedintentionallytosupportwhoorwhatwilluseit,andtosupporthowit’s expectedtobeused. Page2of10
What You Will Be Creating Next,youneedanideaofwhatyouwillbecreatingforthisproject,bothinthisandlateriterations.An outlineisgivenbelow.Unlessyouhaveworkedwithrelationaldatabasespreviously,youwilllikelynot understandallofthetermsusedatthispoint.Donotworry.Youwilllearnthetermsasyouneedto developtheitemstheyrelateto.Keepinmindthattheiterationsbuildoneachother,soasyouprogress throughtheiterations,youwillfirstrevisewhatyoudevelopedinprioriterations,thenaddadditional material.Asimilaroutlineisprovidedineveryiterationtohelpyoukeeptrackofwhatyouhave completedandwillbecompleting.
Page3of10
Current Iteration
Iteration1
Iteration2
Iteration3
Future Iterations
Iteration4
Iteration5
ProjectDirectionOverview–Youprovideanoverviewthatdescribeswhothe databasewillbefor,whatkindofdataitwillcontain,howyouenvisionitwillbe used,andmostimportantly,whyyouareinterestedinit. UseCasesandFields–Youprovideusecasesthatenumeratestepsofhowthe databasewillbetypicallyused,alsoidentifysignificantdatabasefieldsneededto supporttheusecase. SummaryandReflection–Youconciselysummarizeyourprojectandtheworkyou havecompletedthusfar,andadditionallyrecordyourquestions,concerns,and observations,sothatyouandyourfacilitatororinstructorareawareofthemand cancommunicateaboutthem. StructuralDatabaseRules–Youdefinestructuraldatabaseruleswhichformally specifytheentities,relationships,andconstraintsforyourdatabasedesign. ConceptualEntityRelationshipDiagram(ERD)–YoucreateaninitialERD,the universallyacceptedmethodofmodelingandvisualizingdatabasedesigns,to visualizetheentitiesandrelationshipsdefinedbythestructuraldatabaserules. Specialization‐GeneralizationRelationships–Youaddoneormorespecialization‐ generalizationrelationships,whichallowsoneentitytospecializeanabstractentity, toyourstructuraldatabaserulesandERD. InitialDBMSPhysicalERD–YoucreateaninitialDBMSphysicalERD,whichistiedto aspecificrelationaldatabasevendorandversion,withSQL‐basedconstraintsand datatypes. FullDBMSPhysicalERD–Youdefinetheattributesforyourdatabasedesignand addthemtoyourDBMSPhysicalERD. Normalization–YounormalizeyourDBMSphysicalERDtoreduceoreliminatedata redundancy. TablesandConstraints–YoucreateyourtablesandconstraintsinSQL. IndexPlacementandCreation–Tospeedupperformance,youidentifycolumns needingindexesforyourdatabase,thencreatetheminSQL. Reusable,Transaction‐OrientedStoreProcedures–Youcreateandexecutereusable storedproceduresthatcompletethestepsoftransactionsnecessarytoadddatato yourdatabase. HistoryTable–Youcreateahistorytabletotrackchangestovalues,anddevelopa triggertomaintainit. QuestionsandQueries–Youdefinequestionsusefultotheorganizationor applicationthatwilluseyourdatabase,thenwritequeriestoaddressthequestions.
Page4of10
Project Direction Overview WhatkindofdatashouldIcapture?HowshouldIchooseaprojectdirection?WheredoIstart?Youmay havemanyquestionslikethis,buttheanswerissimple.Choosesomethingyou’reinterestedin.The excitingpartis,youcancreateadatabaseaboutwhateveryou’dlike!Youwillbeworkingwiththisdata alotduringtheterm,andwewantyoutoenjoyit. Onceyou’veselectedsomethingofinterest,youneedtoexplainyourchoicesoyourfacilitatoror instructorwillknowwhatyou’reworkingtoward.Createanoverviewinyourdesigndocumentwhich describeswhothedatabasewillbefor,whatkindofdataitwillcontain,andhowyouenvisionitwillbe used,andmostimportantly,whyyouareinterestedinit. Sinceadatabaseisnotusedinisolation,yourprojectoverviewwilllikelyhavesomereferencestonon‐ database‐relatedareassuchasapplicationfunctionalityororganizationalprocesses.Suchreferencesare justfineandexpected,aslongastheyhelpyouandyourfacilitatororinstructorunderstandyour database.Justkeepinmindthatyouwillbefocusedondesigningandimplementingthedatabase componentinthiscourse. Tohelpguideyou,Iselectmyownprojectinanareaofmyinterest,andgiveyouexamplesinthisand allremainingtermprojectiterations.Mineisonlyoneproject,sopleasedonotletmychoiceslimityour creativityorprojectdirection.Myprojectisadatabaseforamobileapplication,butyoumayfindthat yourprojectissomethingdrasticallydifferentthanmine,whichisexpected.Further,youmaycreatea projectthatismuchbetterthanmine.Thinkoftheseexamplesassomethingthatgivesyouabasicidea ofhowtoproceed,nothingmore.FirstIprovideanoverviewofmyproject. TrackMyBuys Project Direction Overview Iwouldliketodevelopamobileappwhichtracksallpurchasessomeonemakes,named “TrackMyBuys”.Whensomeoneusesthisapp,theywillhavetheirfullpurchasehistoryattheir disposalacrossallstores.Typically,whenapersonpurchasessomethingonline,theycanonlysee theirpurchasehistorywiththatsamevendor.Iftheypurchasefrom20differentstores,theyneed tovisit20differentwebsitestoseealloftheirpurchasehistory.Further,thereisnohistorythey canaccessforwhentheypurchaseinabrick‐and‐mortarstore.Peopleliketoknowwhatthey purchaseandwhenformanyreasons,includingreturns,buyingorrecommendingasimilar productpossiblymanyyearsaftertheoriginalpurchase,andeventrackingdownwarrantieswhen somethingbreaks.TrackMyBuyswillstorepurchasesmadeacrossallstores,makingittheonestop foranypurchasehistory. Hereisaresomebriefexamplesofhowsomeonewouldusetheapplication.Ariamakesmany onlinepurchases.Acoupleweeksago,shepurchasedathrowablecamerafromAmazon,anda virtualrealityheadsetfromEBay.Usingabrowserextension,TrackMyBuysautomaticallyrecorded eachpurchase.AriaalsovisitedanearbyOldNavystoreandpurchasedasweater,whichshethen manuallyrecordedintheapp.Today,herfriendBriannatoldhershereallylikesthethrowable cameraaswellasthesweater,andwantstobuythemherself.Ariaquicklylooksupherpurchases inTrackMyBuysonhersmartphone,thenforwardstheinformationontoBrianna.IfAriaever needstolookupherotherpurchasesinthefuture,TrackMyBuyswillbeatherdisposal,evenas manyyearspassby. Page5of10
WhileobviouslytherewillbeasignificantprogrammingcomponentforTrackMyBuys,forthis courseIamfocusingonthedatabasecomponent.Thedatabasewillstorethenamesandlocations forthestorespurchasedfrom.Itwillrecordthedetailsofeachpurchasesuchasthedateand priceofthepurchase.SinceTrackMyBuyswillbeusedbymanypeople,thedatabasewillneedto associatethepurchaseswithdifferentaccounts.SinceIplantochargeforpremiumfeatures,there willneedtobesomekindofbillinginformation.I’msuretherearedetailsI’mnotthinkingofthis week,butthesewillbecomeapparentinfutureweeks. Noticethatintheoverview,Ididnotattempttoprovideeverydetail,butratherprovidedahigh‐level summary.Thedetailswillbeitemizedinothersectionsofthedesigndocument.
Use Cases and Fields Forthiscomponentofyourdesigndocument,youdefineusecasesthatenumeratestepsofhowthe databasewillbetypicallyused.Insoftwareengineering,ausecaseisalistofstepsdefininginteractions betweenapersonandthesystem.Usescasesarecommonlyusedtohelpformallydescribean application.Thiseffortwillhelpyouandyourfacilitatorunderstandhowapersonorapplication interactswithyourdatabase.Thefocusshouldbeonhowyourdatabasewillbetypicallyused. Foreachusecase,youalsoidentifysignificantdatabasefieldsneededtosupporttheusecase.Thishelps youdeterminehowtheusecaseaffectsthedatabasespecifically,asopposedtohowitaffectsthe generalsystemorapplication.Giveeachfieldareasonablename,explainwhatkindofdataitstores, andwhysuchafieldisneededtosupporttheusecase.Donotworryaboutdiscerningeverylastfield; thiswillbedetailedinothersectionsofthedesigndocument.Hereyouareidentifyingthesignificant fieldsthatthedatabasewillclearlyneedtostoretosupporttheusecases. Defineatleastthreeusecasesforthisiteration.Yourdesigndocumentwillultimatelyendupwithmore thanthree;however,Idonotwantyoutoforcecreatingmoreifthreeisallyoucanforeseeatthispoint. Oftentimesweenvisionadditionalusecasesaswefurtherdefineourdatabasewithmoredetails,and moreusecasescanbeaddedinlateriterations. HerearesomeusecasesandfieldsforTrackMyBuys. TrackMyBuys Use Cases and Fields Oneimportantusageofthedatabaseiswhenapersonsignsupforanaccountandinstallsthe application. AccountSignup/InstallationUseCase 1. ThepersonvisitsTrackMyBuys’websiteorappstoreandinstallstheapplication. 2. Theapplicationasksthemtocreateanaccountwhenitsfirstrun. 3. Theuserenterstheirinformationandtheaccountiscreatedinthedatabase. 4. Theapplicationasksthemtoinstallbrowserpluginssothattheirpurchasescanbe automaticallytrackedwhentheymakethem. Fromadatabaseperspective,thisusecaserequiresstoringinformationaboutaccounts(from steps#2and#3).Steps#1and#4applytotheuserandapplicationbutnotthedatabasedirectly. Significantfieldsforanaccountforthisapplicationarelistedinthetablebelow. Page6of10
Field AccountName
FirstName
WhatitStores Thisfieldstoresasummary nameassociatedwitheach account, Thisisthefirstnameofthe accountholder.
LastName
Thisisthelastnameofthe accountholder.
CustomerSince
Thisisthedatetheaccount whatwascreated.
AccountBalance
Thisisthebalanceowedby thecustomer.
Whyit’sNeeded Incasethesamepersonhasmorethan oneaccount,theycanselectthecorrect onefromadropdownlist. Thisisnecessaryfordisplayingthe person’snameonscreensandaddressing themwhensendingthememailsorother communications. Thisisnecessaryfordisplayingthe person’snameonscreensandaddressing themwhensendingthememailsorother communications. Thisisusefulfordeterminingtheageof anaccount,whichisusefulforavarietyof reasons,suchasgivingdiscountstolong‐ termcustomers,customerretention,etc … Thisisusefultokeeptrackofcustomers thatowemoneytousetheapplication.
Anotherimportantusageofthedatabaseiswhenanonlinepurchaseismadeandautomatically recordedinTrackMyBuysviabrowserextensions. AutomaticPurchaseTrackingUseCase 1. Thepersonvisitsanonlineretailerandmakesapurchase. 2. TheTrackMyBuysbrowserplugindetectsthatthepurchaseismade,andrecordstherelevant informationinthedatabasesuchasthepurchasedate,price,product,store,etc. Step#2highlightsthatthedatabasewillstorerelevantinformationaboutanonlinepurchase. Significantfieldsaredetailedbelow. Field WhatitStores Whyit’sNeeded PurchaseDate Thisisthedateofthe Thisisusefulsothatthepersonknowson onlinepurchase. whatdaytheymadethepurchase,andso thattheycansearchforpurchasesby date. PurchasePrice Thisisthetotalcostofthe Thisisusefulsothatthepersonknows howmuchmoneytheyspentona purchase. purchase,sotheycansearchfor purchasesbyprice. Product Thisisthenameofthe Thisisnecessaryforsothepersonknows productthatwas whatproducttheybought. purchased. Store Thisisthenameofthe Thisisnecessarysothepersonknowsat storewherethepurchase whatstoretheymadethepurchase. Page7of10
URL
tookplace. ThisistheURLwherethe purchasetookplaceonline.
Thisisusefulsothepersoncouldgoback tothesameonlinestoreandknowwhat websitetheywerevisitingwhenthey madethepurchase.
Anotherimportantusageiswhenapersondecidestolookuppastpurchases. PurchaseLookupUseCase 1. ThepersonsignsintoTrackMyBuys. 2. Thepersonselectstheoptiontolookuppastpurchases. 3. TrackMyBuyspullsashortlistofrecentpurchasesfromthedatabase,andalsogivestheuser theoptiontosearch. 4. Theusersearchesbaseduponadaterange,whichcausesadatabasesearch. 5. Theapplicationpullsallpurchasesmatchingthecriteriafromthedatabase. 6. Theuserselectsthepurchasetheyareinterestedin. 7. TrackMyBuysdisplaysallrecordedinformationaboutthepurchase. 8. Atthatpoint,theusercancloseoutofthepurchase,orsharethepurchasebyselectingthe Shareoption. Thedatabasewouldmakeuseofthefieldsalreadyhighlightedforthesecondusecase,Automatic PurchaseTrackingUseCase.Thisusecasehelpsusunderstandmoreofhowtheuserand applicationwouldinteractwiththedatabase,butdoesnotappeartointroduceadditional databasefieldsbeyondthesecondusecase. NoticethatafterreadingthroughtheusecasesforTrackMyBuys,youhaveabetterideaofhowthe databasewillbeused,howtheapplicationwillinteractwiththedatabase,andwhatdatathedatabase willstore.
Summary and Reflection Atthispoint,youandyourfacilitatororinstructorhaveanideaofwhatkindofdatabaseyouare creating,whichisgreat!Totiethingstogether,conciselysummarizeyourprojectandtheworkyouhave completedinyourdesigndocument.Yoursummaryneednotbelong.Expressbrieflythemainpurpose ofyourprojectandafewsignificantdetails,totietogethertheideasyouhaveforyourproject. Additionally,youmayhavesomequestions,concerns,andotherobservations.Tak...