Kế toán doanh nghiệp - Chapter 7: Data flow diagramming

Learning objectives Nature and purpose of DFDs DFD symbols Leveling and balancing Database design Normal forms

pptx34 trang | Chia sẻ: thuychi11 | Lượt xem: 466 | Lượt tải: 0download
Bạn đang xem trước 20 trang tài liệu Kế toán doanh nghiệp - Chapter 7: Data flow diagramming, để xem tài liệu hoàn chỉnh bạn click vào nút DOWNLOAD ở trên
Chapter 7Data Flow DiagrammingOutlineLearning objectivesNature and purpose of DFDsDFD symbolsLeveling and balancingDatabase designNormal formsLearning objectivesExplain the symbols and design considerations associated with DFDs.Compare and contrast flowcharts and DFDs with regard to purpose, content, structure, and use in accounting information systems.Discuss ways DFDs are used in AIS work.Construct a leveled set of DFDs.Design normalized database tables from a DFD.Nature and purpose of DFDsNot as widely used as flowcharts in accounting practiceTwo main purposesUnderstanding a business processUnderstanding the relational database that underlies the AISFocus on dataDFD symbolsprocessexternal entitydata flowdata storeDFD symbolscustomer order1.0Take customer ordercustomerorder databaseLeveling and balancingData flow diagrams are prepared in leveled sets. Each level reveals more detail than the one before it.Levels must be balanced, which means that external entities and data flows at the boundary cannot “disappear” between levels.Leveling and balancingLevel namesContext diagramLevel Zero diagramLevel One diagramsLevel Two diagramsAnd so on. . .Leveling and balancingContext diagramHighest level view of the systemExactly one in a leveled setExactly one processOne or more external entitiesNo data storesCustomer0Order taking processCustomerorderInvoiceLeveling and balancingLevel Zero diagramExactly one in a leveled setMore detail than the context diagramPreserve data flows at the boundaryCustomerCustomerorderInvoice1.0Process customer order.2.0Bill customer.Processed customerorderLeveling and balancingLevel One diagramMay be more than one in a leveled setMore detail than the Level Zero diagramEach Level One focused on a single “bubble” from Level ZeroPreserve data flows at the boundarySee the example on the next slide, which “explodes” Process 1.0 (Process customer order) from the Level Zero diagram.Leveling and balancingCustomerCustomerorder1.1Verify customer order.Verified customerorder1.2Evaluate customer credit.Customer databaseCreditinquiryCreditdecisionProcessed customer orderLeveling and balancingProcesses are decomposed (“exploded”) until they are primitive. Processes may be decomposed to different levels.Numbering conventionsLevel One diagram of Process 2.0: 2.1, 2.2Level Two diagram of Process 1.2: 1.2.1, 1.2.2Database designObjectsTerminologyNormal formsDatabase designObjects: tablesEvery relational database must include at least one table.Most will include multiple tablesOrganizationFields (columns)Records (rows)See the example on the next slide.Database designStudent table in design viewStudent table in datasheet viewDatabase designObjects: queriesSets of instructions that examine current data in tables and / or other queriesOutput data according to the instructionsCan include simple computations (e.g., total, average)See the example on the next slideDatabase designQuery in design viewQuery in datasheet viewDatabase designObjects: formsAllow a user to interact with a database even if they know nothing about design and structureTwo uses: data input, data lookupSee the example on the next slideDatabase designForm in design viewForm in form viewDatabase designObjects: reportsWell formatted output of a relational databaseCan be based on tables and / or queriesCan incorporate simple calculationsSee the example on the next slideDatabase designReport in report view(Design view not shown)Database designTerminologyPrimary key: a field in a table that uniquely identifies every record in that tableForeign key: a primary key in one table that is included in another table for linking purposesCompound primary key: two or more fields in a table that together comprise its primary keyDatabase designTerminologyJunction tableA table that joins together two separate tables.Required when the two separate tables have a “many-to-many” relationshipEvery student may enroll in many classes.Every class has many students.Named by joining the separate table namesStudent tableClass tableStudent / class tableSee the illustration on the next slide This is the junction table.Database designRelationship grid Database designNormal formsTable characteristics that ensure a relational database is organized as efficiently and effectively as possibleMinimize space allocationsFacilitate searchesEstablish relationships between tablesDatabase designFirst normal form (1NF)Eliminates repeating groupsSecond normal form (2NF)Eliminates repeating groupsEliminates redundant dataThird normal form (3NF)Eliminates repeating groupsEliminates redundant dataEliminates columns not dependent on the primary keyDatabase designThe next few slides show you how to start with a “flat file” (such as a spreadsheet) and create normalized database tables.With practice, you’ll be able to design normalized tables “from scratch.”The following example is drawn from the 23 January 2014 post on Dr. Hurt’s AIS blog.Normal formsThis data array is a “flat file” comprising two fields and five records. It is not normalized, as the “courses” field includes repeating groups of data (i.e., two courses in one field).To put the array in 1NF, we need to eliminate repeating groups.Normal formsThis array, while not fully normalized, is closer to that state. Note that we could search for specific course prefixes and / or numbers more easily than in the flat file.To put the data in 2NF, we need to eliminate redundant data.Normal formsNeither table has repeating groups or redundant data; however, we’re missing key information: which students are in which courses?Junction tableCompletes 2NF by marrying data from two other tablesRequires a compound primary keyMany-to-many relationshipEach student can take many courses.Each course can have many students.Normal formsTo put the data in 3NF, we must ensure that each table contains only fields that give us more information about the primary key.Student table: last name, first name, area code, phone numberCourse table: course title, instructor, building, classroom, section numberStudent / course table: probably does not need any information beyond the primary keys of the two other tablesNormal forms
Tài liệu liên quan