SlideShare a Scribd company logo
1 of 24
Download to read offline
UML for Data Architects:
A Painless Introduction

Dr. Vladimir Bacvanski
vladimir.bacvanski@scispike.com
About the Speaker: Dr. Vladimir Bacvanski

 Mission: to make organizations successful in
  solving problems through adoption of modern
  software technologies
  – Founder of SciSpike – a training and consulting firm
    specializing in advanced software technologies
  – Over two decades of experience with software and data
    technologies
  – Vladimir has helped a number of organizations
    including US Treasury, Federal Reserve Bank, US Navy,
    IBM, Dell, Hewlett Packard, JP Morgan Chase, Nokia,
                                      g
    Lucent, Nortel Networks, General Electric, BAE Systems,
    AMD, and others
  – Frequent speaker at leading industry events.
       q        p              g        y
  – For three years in a row awarded the title "IBM
    Information Champion" for his contributions to the
    information management community
                       g                  y


                        www.scispike.com   Copyright © SciSpike 2011   2
Outline

 What is UML?
 How to approach UML? (aka "Avoiding pain")
 UML diagrams: use only what you need!
         g             y      y
 Representing structure: class (aka type) diagrams
 UML for database design
 Automation
 Conclusion




                   www.scispike.com   Copyright © SciSpike 2011   3
What is UML?

 The UML is a graphical language for
  software intensive systems
    f
  – Note: UML is just a notation:
    the way we visualize our decisions
     h           i li        d ii
 UML covers a broad area of software
  development
  d l         t
 UML is a standard: it enables you to
  express your models i a way th t
                  d l in        that
  can be understood by others




                   www.scispike.com   Copyright © SciSpike 2011   4
Models and Diagrams




 Model is a view of a system from a particular perspective
 Diagram visually presents elements of a model
  – One model can be presented with several diagrams, each
    focusing on a separate aspect

                   www.scispike.com   Copyright © SciSpike 2011   5
UML Diagrams




                                                 Diagrams in italics are introduced in UML 2

           www.scispike.com   Copyright © SciSpike 2011                                        6
Choose your Approach to UML!

        Painful                                                  Painless

• Focus on > 95% of UML                   • Focus on < 5% of UML
  that
  th t you d 't need
           don't     d                      that
                                            th t you need d
• Start with a 1000+                      • Start with a subset
  pages UML Reference                       relevant to data
• Avoid practical                           modeling
  examples                                • Seek practical guides
• Use UML for all the                       and examples
  wrong reasons                           • Use UML to
                                            communicate and
                                            automate

                  www.scispike.com   Copyright © SciSpike 2011              7
Modeling Data with UML Class Diagrams

 A subset of UML Class Diagram is very close to notations
  used in d
     d data modeling
                 d l
 UML Class Diagrams have features not needed for data
  modeling:
    d l
  – Operations (methods)
  – Visibility (public, private, …)
 We can use only a subset that make sense for data modeling:
  – Classes (aka "types")
  – Attributes
  – Associations
  – Generalization

                    www.scispike.com   Copyright © SciSpike 2011   8
UML Classes and Attributes
                                    Class
                                    Similar to entity in ERD.
    Customer
                                    Class name
                                    Typically capitalized.

                                    Attribute Compartment
                                    The only compartment we care about. 
                                    UML classes can have other 
                                    compartments, e.g. for operations.
                                    It is fine to skip parts we don't need!
                                                     pp



                                                                    Note:
                                                                    N t
Attribute Name   Attribute Type                                     High level class 
Typically        E.g. String, Integer,…                             diagrams typically don't 
lowercase.       but also other class names                         need primary and 
                                                                    foreign keys. 
                 www.scispike.com       Copyright © SciSpike 2011                               9
UML Associations
 Association             Association Name                        Multiplicity
                         Usually skipped.                        *: zero or many
                                                                 1..*: one or many
                                                                 0..1: zero or one




 Association Role
 Start from a class, follow the 
 Start from a class follow the                                  Note:
 association, read the role of the                              Foreign key attributes are 
                                                                not needed
 associated objects.


                       www.scispike.com   Copyright © SciSpike 2011                           10
Navigability


                    1..*                             *
     Person                                                        Address
                                       homeAddress




 High level diagrams typically do not show navigability
 Navigability is a design decision!
  – It is a bad practice to assign navigability prematurely
  – Typically not needed for modeling when we target
    relational databases


                    www.scispike.com   Copyright © SciSpike 2011             11
Associations vs. Attributes


       Person
       P                       Multiplicity
                               M lti li it                                   Company
                                                                             C


 employer: Company[*]
   p y        p y[ ]                                                   employee: Person[1..*]
                                                                         p y           [    ]




 In UML, attributes and associations are equivalent!
 Choose the representation that is more suitable to the
  reader
 Important relationships are often represented as
  associations – they bring the visual emphasis

                        www.scispike.com   Copyright © SciSpike 2011                            12
Association Class




                                                                  Association 
                                                                  Class
                                                                  Cl




 Association class allows to attach information to an
  association
  – Often refined into two associations to a class


                   www.scispike.com   Copyright © SciSpike 2011                  13
Association Class Refined




 Association classes are commonly refined in lower level
                                 y
  diagrams



                   www.scispike.com   Copyright © SciSpike 2011   14
Semantics of Aggregation and Composition

                                           1
          Car                                                     Engine


                               Aggregation
                                           1
          Car                                                     Engine


                               Composition

 Aggregation: shortcut for "has" relationship
                             has
  – Does not have a well defined semantics. Use sparingly!
 Composition lifetime of the owner determines the lifetime
  Composition:
  of the owned objects
  – Similar to "cascading"
                cascading
                   www.scispike.com   Copyright © SciSpike 2011            15
Generalization (aka Inheritance)

                                     Employee
                                                                             Generalization
                                                                             G     li i




         Engineer                        Manager                          TechWriter




 Subclasses extend superclasses with additional attributes
  and associations
 This relationship eventually needs to be mapped to tables
  for relational database design
  – Several solutions possible with different performance impact. Choice
                                                          impact
    depends on the typical pattern of usage.
                      www.scispike.com        Copyright © SciSpike 2011                       16
Constraints




 Constraints can be expressed as:
  – Plain text
  – OCL: Object Constraint Language, part of UML
    • Not common in mainstream projects
    • Enforcable



                   www.scispike.com   Copyright © SciSpike 2011   17
Organizing UML Models: Packages

                                          A package is a
                                           structuring element
  Customer
 Management                                – It contains other
                                             elements and
                                             diagrams
   Sales
                                          P k
                                           Packages are important
                                                          i
                                           for managing
                                           complexity of models
                                          Prefer models organized
  Inventory                                into packages to huge
                                           diagrams


              www.scispike.com   Copyright © SciSpike 2011          18
Mapping UML to ER Models…

 Class  Entity
  – Add primary key
 Simple Attribute Type  Column Type
 Complex Attribute Type  Relationship to an entity for the
  attribute type
 Association  Foreign Key relationships
  – Use role names for foreign keys
  – Many-to-many association  add an associative table
  – Aggregation: treat as ordinary relationships




                   www.scispike.com   Copyright © SciSpike 2011   19
…Mapping UML to ER Models

 Generalization: use the usual mappings:
  – Table per class hierarchy
  – Table per subclass
  – Table per concrete class
 Constraints
  – Set constraints on the database
  – Some only enforceable in application logic
             y                 pp          g



  This is just a simplified set of rules to get you going!


                     www.scispike.com   Copyright © SciSpike 2011   20
UML for Database Design




 Agile teams often use UML for both software and database
  design
 UML data modeling profile introduces extensions to UML:
  – <<PK>>, <<FK>>, <<Auto Generated>>, <<Not Null>>,
    <<View>>, <<Stored Procedures>>,…
 Use relational data types
  – String  CHAR(x), VARCHAR(x)

                    www.scispike.com   Copyright © SciSpike 2011   21
Automation

                                                                        Code

                                 Transformer
                                                                        DDL

          Input
                                                                        Models
         Models
                                                                    Output

 Tools can convert from UML to ERD and vice versa
 Model transformation tools operate at a MOF/EMF level and
  can transform UML to various targets
  – Visual Domain Specific Languages (DSLs) based on UML may provide
    better alignment with the p
              g               problem domain than vanilla UML

                     www.scispike.com   Copyright © SciSpike 2011                22
Conclusion

 You will need just a small part of UML!
 UML is a common starting point for data models
 Mapping of UML to ER is quite straightforward
    pp g                  q          g
 Knowing UML makes you a more significant player in the
  software development p
                 p     process




                   www.scispike.com   Copyright © SciSpike 2011   23
Getting in Touch

 Email: vladimir.bacvanski@scispike.com
 Blog: http://www.OnBuildingSoftware.com/
 Twitter: http://twitter.com/OnSoftware
              p
 LinkedIn: http://www.linkedin.com/in/VladimirBacvanski


 SciSpike Training and Consulting:
  http://www.scispike.com
  http://www scispike com
  – Related training for data architects:
    • Visual Modeling with UML
    • Mastering Data Modeling with InfoSphere Data Architect


                   www.scispike.com   Copyright © SciSpike 2011   24

More Related Content

What's hot

Microsoft SQL Server Analysis Services (SSAS) - A Practical Introduction
Microsoft SQL Server Analysis Services (SSAS) - A Practical Introduction Microsoft SQL Server Analysis Services (SSAS) - A Practical Introduction
Microsoft SQL Server Analysis Services (SSAS) - A Practical Introduction Mark Ginnebaugh
 
Most Common Data Governance Challenges in the Digital Economy
Most Common Data Governance Challenges in the Digital EconomyMost Common Data Governance Challenges in the Digital Economy
Most Common Data Governance Challenges in the Digital EconomyRobyn Bollhorst
 
Tableau Training For Beginners | Tableau Tutorial | Tableau Dashboard | Edureka
Tableau Training For Beginners | Tableau Tutorial  | Tableau Dashboard | EdurekaTableau Training For Beginners | Tableau Tutorial  | Tableau Dashboard | Edureka
Tableau Training For Beginners | Tableau Tutorial | Tableau Dashboard | EdurekaEdureka!
 
Business Drivers Behind Data Governance
Business Drivers Behind Data GovernanceBusiness Drivers Behind Data Governance
Business Drivers Behind Data GovernancePrecisely
 
Databricks + Snowflake: Catalyzing Data and AI Initiatives
Databricks + Snowflake: Catalyzing Data and AI InitiativesDatabricks + Snowflake: Catalyzing Data and AI Initiatives
Databricks + Snowflake: Catalyzing Data and AI InitiativesDatabricks
 
Working with Microsoft Power Business Inteligence Tools - Presented by Atidan
Working with Microsoft Power Business Inteligence Tools - Presented by AtidanWorking with Microsoft Power Business Inteligence Tools - Presented by Atidan
Working with Microsoft Power Business Inteligence Tools - Presented by AtidanDavid J Rosenthal
 
Data Virtualization: An Introduction
Data Virtualization: An IntroductionData Virtualization: An Introduction
Data Virtualization: An IntroductionDenodo
 
Power bi introduction
Power bi introductionPower bi introduction
Power bi introductionBishwadeb Dey
 
Azure data platform overview
Azure data platform overviewAzure data platform overview
Azure data platform overviewJames Serra
 
Business Intelligence Overview
Business Intelligence OverviewBusiness Intelligence Overview
Business Intelligence Overviewnetpeachteam
 
Oracle 11g – Inteligência em Banco de Dados
Oracle 11g – Inteligência em Banco de DadosOracle 11g – Inteligência em Banco de Dados
Oracle 11g – Inteligência em Banco de DadosDaniela Macedo
 
Oracle analytics Live September 2021
Oracle analytics Live September 2021Oracle analytics Live September 2021
Oracle analytics Live September 2021Benjamin Arnulf
 
Dimensional modeling in oracle sql developer
Dimensional modeling in oracle sql developerDimensional modeling in oracle sql developer
Dimensional modeling in oracle sql developerJeff Smith
 
Data Architecture Best Practices for Today’s Rapidly Changing Data Landscape
Data Architecture Best Practices for Today’s Rapidly Changing Data LandscapeData Architecture Best Practices for Today’s Rapidly Changing Data Landscape
Data Architecture Best Practices for Today’s Rapidly Changing Data LandscapeDATAVERSITY
 
Data Quality Best Practices
Data Quality Best PracticesData Quality Best Practices
Data Quality Best PracticesDATAVERSITY
 
Data Visualization With Tableau | Edureka
Data Visualization With Tableau | EdurekaData Visualization With Tableau | Edureka
Data Visualization With Tableau | EdurekaEdureka!
 
Splunk Business Analytics
Splunk Business AnalyticsSplunk Business Analytics
Splunk Business AnalyticsCleverDATA
 

What's hot (20)

Microsoft SQL Server Analysis Services (SSAS) - A Practical Introduction
Microsoft SQL Server Analysis Services (SSAS) - A Practical Introduction Microsoft SQL Server Analysis Services (SSAS) - A Practical Introduction
Microsoft SQL Server Analysis Services (SSAS) - A Practical Introduction
 
Most Common Data Governance Challenges in the Digital Economy
Most Common Data Governance Challenges in the Digital EconomyMost Common Data Governance Challenges in the Digital Economy
Most Common Data Governance Challenges in the Digital Economy
 
Tableau Training For Beginners | Tableau Tutorial | Tableau Dashboard | Edureka
Tableau Training For Beginners | Tableau Tutorial  | Tableau Dashboard | EdurekaTableau Training For Beginners | Tableau Tutorial  | Tableau Dashboard | Edureka
Tableau Training For Beginners | Tableau Tutorial | Tableau Dashboard | Edureka
 
Power bi
Power biPower bi
Power bi
 
Business Drivers Behind Data Governance
Business Drivers Behind Data GovernanceBusiness Drivers Behind Data Governance
Business Drivers Behind Data Governance
 
Databricks + Snowflake: Catalyzing Data and AI Initiatives
Databricks + Snowflake: Catalyzing Data and AI InitiativesDatabricks + Snowflake: Catalyzing Data and AI Initiatives
Databricks + Snowflake: Catalyzing Data and AI Initiatives
 
Power BI Overview
Power BI Overview Power BI Overview
Power BI Overview
 
Working with Microsoft Power Business Inteligence Tools - Presented by Atidan
Working with Microsoft Power Business Inteligence Tools - Presented by AtidanWorking with Microsoft Power Business Inteligence Tools - Presented by Atidan
Working with Microsoft Power Business Inteligence Tools - Presented by Atidan
 
Data Virtualization: An Introduction
Data Virtualization: An IntroductionData Virtualization: An Introduction
Data Virtualization: An Introduction
 
Power bi introduction
Power bi introductionPower bi introduction
Power bi introduction
 
Azure data platform overview
Azure data platform overviewAzure data platform overview
Azure data platform overview
 
Business intelligence
Business intelligenceBusiness intelligence
Business intelligence
 
Business Intelligence Overview
Business Intelligence OverviewBusiness Intelligence Overview
Business Intelligence Overview
 
Oracle 11g – Inteligência em Banco de Dados
Oracle 11g – Inteligência em Banco de DadosOracle 11g – Inteligência em Banco de Dados
Oracle 11g – Inteligência em Banco de Dados
 
Oracle analytics Live September 2021
Oracle analytics Live September 2021Oracle analytics Live September 2021
Oracle analytics Live September 2021
 
Dimensional modeling in oracle sql developer
Dimensional modeling in oracle sql developerDimensional modeling in oracle sql developer
Dimensional modeling in oracle sql developer
 
Data Architecture Best Practices for Today’s Rapidly Changing Data Landscape
Data Architecture Best Practices for Today’s Rapidly Changing Data LandscapeData Architecture Best Practices for Today’s Rapidly Changing Data Landscape
Data Architecture Best Practices for Today’s Rapidly Changing Data Landscape
 
Data Quality Best Practices
Data Quality Best PracticesData Quality Best Practices
Data Quality Best Practices
 
Data Visualization With Tableau | Edureka
Data Visualization With Tableau | EdurekaData Visualization With Tableau | Edureka
Data Visualization With Tableau | Edureka
 
Splunk Business Analytics
Splunk Business AnalyticsSplunk Business Analytics
Splunk Business Analytics
 

Viewers also liked

Dache: A Data Aware Caching for Big-Data Applications Using the MapReduce Fra...
Dache: A Data Aware Caching for Big-Data Applications Usingthe MapReduce Fra...Dache: A Data Aware Caching for Big-Data Applications Usingthe MapReduce Fra...
Dache: A Data Aware Caching for Big-Data Applications Using the MapReduce Fra...Govt.Engineering college, Idukki
 
UML and Data Modeling - A Reconciliation
UML and Data Modeling - A ReconciliationUML and Data Modeling - A Reconciliation
UML and Data Modeling - A Reconciliationdmurph4
 
Data Modeling for Big Data
Data Modeling for Big DataData Modeling for Big Data
Data Modeling for Big DataDATAVERSITY
 
Win Friends and Influence People... with DSLs
Win Friends and Influence People... with DSLsWin Friends and Influence People... with DSLs
Win Friends and Influence People... with DSLsVladimir Bacvanski, PhD
 
High performance database applications with pure query and ibm data studio.ba...
High performance database applications with pure query and ibm data studio.ba...High performance database applications with pure query and ibm data studio.ba...
High performance database applications with pure query and ibm data studio.ba...Vladimir Bacvanski, PhD
 
Introduction to Hadoop at Data-360 Conference
Introduction to Hadoop at Data-360 ConferenceIntroduction to Hadoop at Data-360 Conference
Introduction to Hadoop at Data-360 ConferenceAvkash Chauhan
 
Introduction to Apache Pig
Introduction to Apache PigIntroduction to Apache Pig
Introduction to Apache PigAvkash Chauhan
 
Data-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your Business
Data-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your BusinessData-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your Business
Data-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your BusinessDATAVERSITY
 
CDO Webinar: 2017 Trends in Data Strategy
CDO Webinar: 2017 Trends in Data StrategyCDO Webinar: 2017 Trends in Data Strategy
CDO Webinar: 2017 Trends in Data StrategyDATAVERSITY
 
Data-Ed Slides: Exorcising the Seven Deadly Data Sins
Data-Ed Slides: Exorcising the Seven Deadly Data SinsData-Ed Slides: Exorcising the Seven Deadly Data Sins
Data-Ed Slides: Exorcising the Seven Deadly Data SinsDATAVERSITY
 
Data-Ed Slides: Data Architecture Strategies - Constructing Your Data Garden
Data-Ed Slides: Data Architecture Strategies - Constructing Your Data GardenData-Ed Slides: Data Architecture Strategies - Constructing Your Data Garden
Data-Ed Slides: Data Architecture Strategies - Constructing Your Data GardenDATAVERSITY
 
Data strategy in a Big Data world
Data strategy in a Big Data worldData strategy in a Big Data world
Data strategy in a Big Data worldCraig Milroy
 
Data Governance
Data GovernanceData Governance
Data GovernanceSambaSoup
 
A New Way of Thinking About MDM
A New Way of Thinking About MDMA New Way of Thinking About MDM
A New Way of Thinking About MDMDATAVERSITY
 
Big Data Analytics Strategy and Roadmap
Big Data Analytics Strategy and RoadmapBig Data Analytics Strategy and Roadmap
Big Data Analytics Strategy and RoadmapSrinath Perera
 
Data Governance: Keystone of Information Management Initiatives
Data Governance: Keystone of Information Management InitiativesData Governance: Keystone of Information Management Initiatives
Data Governance: Keystone of Information Management InitiativesAlan McSweeney
 

Viewers also liked (20)

Dache: A Data Aware Caching for Big-Data Applications Using the MapReduce Fra...
Dache: A Data Aware Caching for Big-Data Applications Usingthe MapReduce Fra...Dache: A Data Aware Caching for Big-Data Applications Usingthe MapReduce Fra...
Dache: A Data Aware Caching for Big-Data Applications Using the MapReduce Fra...
 
UML and Data Modeling - A Reconciliation
UML and Data Modeling - A ReconciliationUML and Data Modeling - A Reconciliation
UML and Data Modeling - A Reconciliation
 
Data Modeling for Big Data
Data Modeling for Big DataData Modeling for Big Data
Data Modeling for Big Data
 
Win Friends and Influence People... with DSLs
Win Friends and Influence People... with DSLsWin Friends and Influence People... with DSLs
Win Friends and Influence People... with DSLs
 
Introduction to pig
Introduction to pigIntroduction to pig
Introduction to pig
 
High performance database applications with pure query and ibm data studio.ba...
High performance database applications with pure query and ibm data studio.ba...High performance database applications with pure query and ibm data studio.ba...
High performance database applications with pure query and ibm data studio.ba...
 
Introduction to Hadoop at Data-360 Conference
Introduction to Hadoop at Data-360 ConferenceIntroduction to Hadoop at Data-360 Conference
Introduction to Hadoop at Data-360 Conference
 
Introduction to Apache Pig
Introduction to Apache PigIntroduction to Apache Pig
Introduction to Apache Pig
 
Data-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your Business
Data-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your BusinessData-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your Business
Data-Ed Slides: Data-Centric Strategy & Roadmap - Supercharging Your Business
 
CDO Webinar: 2017 Trends in Data Strategy
CDO Webinar: 2017 Trends in Data StrategyCDO Webinar: 2017 Trends in Data Strategy
CDO Webinar: 2017 Trends in Data Strategy
 
Data-Ed Slides: Exorcising the Seven Deadly Data Sins
Data-Ed Slides: Exorcising the Seven Deadly Data SinsData-Ed Slides: Exorcising the Seven Deadly Data Sins
Data-Ed Slides: Exorcising the Seven Deadly Data Sins
 
Data-Ed Slides: Data Architecture Strategies - Constructing Your Data Garden
Data-Ed Slides: Data Architecture Strategies - Constructing Your Data GardenData-Ed Slides: Data Architecture Strategies - Constructing Your Data Garden
Data-Ed Slides: Data Architecture Strategies - Constructing Your Data Garden
 
Big Data Modeling
Big Data ModelingBig Data Modeling
Big Data Modeling
 
Data strategy in a Big Data world
Data strategy in a Big Data worldData strategy in a Big Data world
Data strategy in a Big Data world
 
Data Governance
Data GovernanceData Governance
Data Governance
 
Data Strategy
Data StrategyData Strategy
Data Strategy
 
A New Way of Thinking About MDM
A New Way of Thinking About MDMA New Way of Thinking About MDM
A New Way of Thinking About MDM
 
8 Steps to Creating a Data Strategy
8 Steps to Creating a Data Strategy8 Steps to Creating a Data Strategy
8 Steps to Creating a Data Strategy
 
Big Data Analytics Strategy and Roadmap
Big Data Analytics Strategy and RoadmapBig Data Analytics Strategy and Roadmap
Big Data Analytics Strategy and Roadmap
 
Data Governance: Keystone of Information Management Initiatives
Data Governance: Keystone of Information Management InitiativesData Governance: Keystone of Information Management Initiatives
Data Governance: Keystone of Information Management Initiatives
 

Similar to UML for Data Architects (20)

SE UML.ppt
SE UML.pptSE UML.ppt
SE UML.ppt
 
Bai giang-uml-14jan14
Bai giang-uml-14jan14Bai giang-uml-14jan14
Bai giang-uml-14jan14
 
Presentation on uml
Presentation on umlPresentation on uml
Presentation on uml
 
UML and Case study
UML and Case study UML and Case study
UML and Case study
 
UNIFIED MODELLING LANGUAGE (UML)
UNIFIED MODELLING LANGUAGE (UML)UNIFIED MODELLING LANGUAGE (UML)
UNIFIED MODELLING LANGUAGE (UML)
 
DISE - OOAD Using UML
DISE - OOAD Using UMLDISE - OOAD Using UML
DISE - OOAD Using UML
 
Ooad lab manual
Ooad  lab manualOoad  lab manual
Ooad lab manual
 
UML.pdf
UML.pdfUML.pdf
UML.pdf
 
Uml Presentation
Uml PresentationUml Presentation
Uml Presentation
 
UML
UMLUML
UML
 
PhD Core Paper Unit 5 _Part 1 Software Design and UML Use Case Modeling.pdf
PhD Core Paper Unit 5 _Part 1 Software Design and UML Use Case Modeling.pdfPhD Core Paper Unit 5 _Part 1 Software Design and UML Use Case Modeling.pdf
PhD Core Paper Unit 5 _Part 1 Software Design and UML Use Case Modeling.pdf
 
Case stydy cs701
Case stydy cs701 Case stydy cs701
Case stydy cs701
 
Uml overview modified
Uml overview modifiedUml overview modified
Uml overview modified
 
Unit-II(STATIC UML DIAGRAMS).ppt
Unit-II(STATIC UML DIAGRAMS).pptUnit-II(STATIC UML DIAGRAMS).ppt
Unit-II(STATIC UML DIAGRAMS).ppt
 
l1_introuml.pdf
l1_introuml.pdfl1_introuml.pdf
l1_introuml.pdf
 
Srs
SrsSrs
Srs
 
Unified Modeling Language
Unified Modeling LanguageUnified Modeling Language
Unified Modeling Language
 
Intro Uml
Intro UmlIntro Uml
Intro Uml
 
Claas diagram
Claas diagramClaas diagram
Claas diagram
 
Claas diagram
Claas diagramClaas diagram
Claas diagram
 

Recently uploaded

Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraDeakin University
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAndikSusilo4
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2Hyundai Motor Group
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxnull - The Open Security Community
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetHyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetEnjoy Anytime
 

Recently uploaded (20)

Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning era
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & Application
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetHyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
 

UML for Data Architects

  • 1. UML for Data Architects: A Painless Introduction Dr. Vladimir Bacvanski vladimir.bacvanski@scispike.com
  • 2. About the Speaker: Dr. Vladimir Bacvanski  Mission: to make organizations successful in solving problems through adoption of modern software technologies – Founder of SciSpike – a training and consulting firm specializing in advanced software technologies – Over two decades of experience with software and data technologies – Vladimir has helped a number of organizations including US Treasury, Federal Reserve Bank, US Navy, IBM, Dell, Hewlett Packard, JP Morgan Chase, Nokia, g Lucent, Nortel Networks, General Electric, BAE Systems, AMD, and others – Frequent speaker at leading industry events. q p g y – For three years in a row awarded the title "IBM Information Champion" for his contributions to the information management community g y www.scispike.com Copyright © SciSpike 2011 2
  • 3. Outline  What is UML?  How to approach UML? (aka "Avoiding pain")  UML diagrams: use only what you need! g y y  Representing structure: class (aka type) diagrams  UML for database design  Automation  Conclusion www.scispike.com Copyright © SciSpike 2011 3
  • 4. What is UML?  The UML is a graphical language for software intensive systems f – Note: UML is just a notation: the way we visualize our decisions h i li d ii  UML covers a broad area of software development d l t  UML is a standard: it enables you to express your models i a way th t d l in that can be understood by others www.scispike.com Copyright © SciSpike 2011 4
  • 5. Models and Diagrams  Model is a view of a system from a particular perspective  Diagram visually presents elements of a model – One model can be presented with several diagrams, each focusing on a separate aspect www.scispike.com Copyright © SciSpike 2011 5
  • 6. UML Diagrams Diagrams in italics are introduced in UML 2 www.scispike.com Copyright © SciSpike 2011 6
  • 7. Choose your Approach to UML! Painful Painless • Focus on > 95% of UML • Focus on < 5% of UML that th t you d 't need don't d that th t you need d • Start with a 1000+ • Start with a subset pages UML Reference relevant to data • Avoid practical modeling examples • Seek practical guides • Use UML for all the and examples wrong reasons • Use UML to communicate and automate www.scispike.com Copyright © SciSpike 2011 7
  • 8. Modeling Data with UML Class Diagrams  A subset of UML Class Diagram is very close to notations used in d d data modeling d l  UML Class Diagrams have features not needed for data modeling: d l – Operations (methods) – Visibility (public, private, …)  We can use only a subset that make sense for data modeling: – Classes (aka "types") – Attributes – Associations – Generalization www.scispike.com Copyright © SciSpike 2011 8
  • 9. UML Classes and Attributes Class Similar to entity in ERD. Customer Class name Typically capitalized. Attribute Compartment The only compartment we care about.  UML classes can have other  compartments, e.g. for operations. It is fine to skip parts we don't need! pp Note: N t Attribute Name Attribute Type High level class  Typically  E.g. String, Integer,…  diagrams typically don't  lowercase.  but also other class names need primary and  foreign keys.  www.scispike.com Copyright © SciSpike 2011 9
  • 10. UML Associations Association Association Name Multiplicity Usually skipped. *: zero or many 1..*: one or many 0..1: zero or one Association Role Start from a class, follow the  Start from a class follow the Note: association, read the role of the  Foreign key attributes are  not needed associated objects. www.scispike.com Copyright © SciSpike 2011 10
  • 11. Navigability 1..* * Person Address homeAddress  High level diagrams typically do not show navigability  Navigability is a design decision! – It is a bad practice to assign navigability prematurely – Typically not needed for modeling when we target relational databases www.scispike.com Copyright © SciSpike 2011 11
  • 12. Associations vs. Attributes Person P Multiplicity M lti li it Company C employer: Company[*] p y p y[ ] employee: Person[1..*] p y [ ]  In UML, attributes and associations are equivalent!  Choose the representation that is more suitable to the reader  Important relationships are often represented as associations – they bring the visual emphasis www.scispike.com Copyright © SciSpike 2011 12
  • 13. Association Class Association  Class Cl  Association class allows to attach information to an association – Often refined into two associations to a class www.scispike.com Copyright © SciSpike 2011 13
  • 14. Association Class Refined  Association classes are commonly refined in lower level y diagrams www.scispike.com Copyright © SciSpike 2011 14
  • 15. Semantics of Aggregation and Composition 1 Car Engine Aggregation 1 Car Engine Composition  Aggregation: shortcut for "has" relationship has – Does not have a well defined semantics. Use sparingly!  Composition lifetime of the owner determines the lifetime Composition: of the owned objects – Similar to "cascading" cascading www.scispike.com Copyright © SciSpike 2011 15
  • 16. Generalization (aka Inheritance) Employee Generalization G li i Engineer Manager TechWriter  Subclasses extend superclasses with additional attributes and associations  This relationship eventually needs to be mapped to tables for relational database design – Several solutions possible with different performance impact. Choice impact depends on the typical pattern of usage. www.scispike.com Copyright © SciSpike 2011 16
  • 17. Constraints  Constraints can be expressed as: – Plain text – OCL: Object Constraint Language, part of UML • Not common in mainstream projects • Enforcable www.scispike.com Copyright © SciSpike 2011 17
  • 18. Organizing UML Models: Packages  A package is a structuring element Customer Management – It contains other elements and diagrams Sales  P k Packages are important i for managing complexity of models  Prefer models organized Inventory into packages to huge diagrams www.scispike.com Copyright © SciSpike 2011 18
  • 19. Mapping UML to ER Models…  Class  Entity – Add primary key  Simple Attribute Type  Column Type  Complex Attribute Type  Relationship to an entity for the attribute type  Association  Foreign Key relationships – Use role names for foreign keys – Many-to-many association  add an associative table – Aggregation: treat as ordinary relationships www.scispike.com Copyright © SciSpike 2011 19
  • 20. …Mapping UML to ER Models  Generalization: use the usual mappings: – Table per class hierarchy – Table per subclass – Table per concrete class  Constraints – Set constraints on the database – Some only enforceable in application logic y pp g This is just a simplified set of rules to get you going! www.scispike.com Copyright © SciSpike 2011 20
  • 21. UML for Database Design  Agile teams often use UML for both software and database design  UML data modeling profile introduces extensions to UML: – <<PK>>, <<FK>>, <<Auto Generated>>, <<Not Null>>, <<View>>, <<Stored Procedures>>,…  Use relational data types – String  CHAR(x), VARCHAR(x) www.scispike.com Copyright © SciSpike 2011 21
  • 22. Automation Code Transformer DDL Input Models Models Output  Tools can convert from UML to ERD and vice versa  Model transformation tools operate at a MOF/EMF level and can transform UML to various targets – Visual Domain Specific Languages (DSLs) based on UML may provide better alignment with the p g problem domain than vanilla UML www.scispike.com Copyright © SciSpike 2011 22
  • 23. Conclusion  You will need just a small part of UML!  UML is a common starting point for data models  Mapping of UML to ER is quite straightforward pp g q g  Knowing UML makes you a more significant player in the software development p p process www.scispike.com Copyright © SciSpike 2011 23
  • 24. Getting in Touch  Email: vladimir.bacvanski@scispike.com  Blog: http://www.OnBuildingSoftware.com/  Twitter: http://twitter.com/OnSoftware p  LinkedIn: http://www.linkedin.com/in/VladimirBacvanski  SciSpike Training and Consulting: http://www.scispike.com http://www scispike com – Related training for data architects: • Visual Modeling with UML • Mastering Data Modeling with InfoSphere Data Architect www.scispike.com Copyright © SciSpike 2011 24