Tracy
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note No publishing access yet

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.

      Your account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

      Your team account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

      Explore these features while you wait
      Complete general settings
      Bookmark and like published notes
      Write a few more notes
      Complete general settings
      Write a few more notes
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Engagement control
    • Make a copy
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Make a copy Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note No publishing access yet

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.

    Your account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

    Your team account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

    Explore these features while you wait
    Complete general settings
    Bookmark and like published notes
    Write a few more notes
    Complete general settings
    Write a few more notes
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    # ERP data warehouse vs data lake ###### tags: `data warehouse` `warehouse` `ERP` `BI` `SAP` `Data modelling` `OLTP` `OLAP` `ERM` `SPM` `CRM` `star` `snowflake` `galaxy` `data lake` `denormalize` `normalize` `granularity` `header` `detail` [TOC] # ERM SPM CRM: ![](https://i.imgur.com/kgxiRS7.png) ==CRM tập trung vào việc tăng doanh thu.== # ERP: ==ERP nhấn mạnh đến việc giảm chi phí.== ![](https://i.imgur.com/DDLqxsO.png) ERP hợp nhất các thông tin được cung cấp bởi các nhóm chức năng khác nhau của tổ chức thông qua các hệ thống như CRM, Quản lý Chuỗi Cung ứng (SCM), Quản lý Nhân sự (HRM). # Data Pineline: ![](https://i.imgur.com/Y0z2ML7.png) # Data Pineline in AWS: ![](https://i.imgur.com/5m2Y3yM.png) # Type of data in Data warehouse: **Meta data:** is information about data. **Summary data:** aggregated data **Raw data:** is a set of information. **Master Data:** This Data is key business information like Customer information , Employee , Materials etc. **Transaction Data:** This is data related to day to day transactions. ## Meta data: EX: * Metadata for a web page may contain the language it is coded in, the tools used to build it, supporting browsers, etc. * Metadata for a digital image may contain the size of the picture, resolution, color intensity, image creation date, etc. * Metadata for a document may contain the document created date, last modified date, it's size, author, description, etc. ## Comparison type of data: ![](https://i.imgur.com/9oVrUrK.png) # Data warehouse: Data warehouse is a ==system that pulls together data from many different sources for reporting and analysis.== Các dữ liệu được lưu trữ phải trải qua quá trình ETL (Extract – Transform – Load) trước khi save data into data mart. ## Data mart: ==USEFUL LINK: http://madhu-dwh.blogspot.com/2013/01/data-warehouse.html== Data ware house collects data from different sources and store the data in Data Marts.(well designed for Reporting tools.) ![](https://i.imgur.com/Nw9Q9YE.png) ![](https://i.imgur.com/DSw5GBz.png) ![](https://i.imgur.com/l4e1utH.png) ![](https://i.imgur.com/JKcehhT.png) ## Data warehouse vs Data mart: Một data warehouse (kho dữ liệu – DWH) là một hệ thống được dùng để lưu trữ thông tin cho việc phân tích và báo cáo. Data Marts là một tập con của data warehouses được dùng để lưu trữ thông tin cần thiết cho một phòng ban hoặc ngay cả một người dùng đơn lẻ. (Tưởng tượng DWH là một toà nhà, data marts là một văn phòng trong toà nhà). Các dữ liệu liên quan được lưu trữ trong công ty DWH. Đối với hầu hết người dùng, họ chỉ cần truy cập vào một tập con dữ liệu cụ thể, giống như bán hàng (sales), sản xuất (production), giao vận (logistic) hoặc marketing ## Modern data warehouse: ![](https://i.imgur.com/MFvKFOv.png ## Data mining: ![](https://i.imgur.com/2d3wcMr.png) ## Data warehouse vs database: Purpose / Time-frame / Format (relational / milti-dimensional)/ Record per request./ SYTEM |Compare|Database|Warehouse| |--------|-------|--------| |Memory consume|less space|more space| |Performance|slow | better ( less join)| ![](https://i.imgur.com/xxQnWkY.png) ![](https://i.imgur.com/wTmfdDb.png) ![](https://i.imgur.com/azyWcge.png) ## OLAP: Data Warehouse và các hệ thông OLAP được xây dựng theo mô hình **dữ liệu đa chiều (multi-dimensional model)** Dữ liệu trong kho dữ liệu được thể hiện dưới dạng đa chiều (Multi Dimension) gọi là khối (cube). Mỗi chiều mô tả một đặc trưng nào đó của dữ liệu. (Nếu số chiều dữ liệu lớn hơn 3, gọi là Hyper Cube) ![](https://i.imgur.com/ZPejElF.png) ![](https://i.imgur.com/dKtLbsY.png) ### OLTP vs OLAP: ![](https://i.imgur.com/iHkNcft.png) ![](https://i.imgur.com/3ZR9VZK.png) ![](https://i.imgur.com/yJCbt9v.png) # NORMALIZATION: :::info The purpose of Normalization to eliminate redundant (repetitive) data and ensure data is stored logically. Normalization divides larger tables into smaller tables and links them using relationships. EX: Header vs Detail table This type of relationship is called one-to-many relationship. It is used when there is one parent record and multiple child records. https://stackoverflow.com/questions/19963735/understanding-header-and-detail-tables Header and Detail table concept is used to perform normalization in SQL. Normalization is the process of reducing data redundancy. We can not remove data redundancy. But we can reduce data redundancy. Data redundancy is duplicating the items. ::: ## Database Normal Forms: Here is a list of Normal Forms: * 1NF (First Normal Form) * 2NF (Second Normal Form) * 3NF (Third Normal Form) * 4NF (Fourth Normal Form) ::: warning * Data in 1NF and 2NF is duplicated & centralized. => Focus on minimizing excuted time + easyto query ( OLAP) * Data in 3NF and 4NF là duy nhất| tường minh | bị chia nhỏ | không trùng lặp | dễ scale up + minimize storage. (OLTP) ::: ## Normalized data vs Denormalized data: ### Normalized data: ![](https://i.imgur.com/6MMAHdS.png) It consumes less space in the database. ### Denormalized data: ![](https://i.imgur.com/Uy8Kjzf.png) Performance: It takes more space in the database than normalized tables. But ==the permanence with be good because of less joins== on the system with all required data in one table. ## Fact and Dimension: ![](https://i.imgur.com/0TaXzih.png) Các chiều mũi tên đều hướng từ các bảng Dim xuống bảng Fact. ### Dim: ![](https://i.imgur.com/xW86hsz.png) ==Dim là các bảng chứa những thuộc tính / phân loại mà chúng ta cần phân tích, theo dõi và thống kê.== Trong 1 Data Model, sẽ có rất nhiều bảng Dimension, và dung lượng của các bảng này thường rất nhỏ, đa số tầm khoảng < 100 dòng. ### Fact: ![](https://i.imgur.com/b1VMLhT.png) ==Bảng Fact chứa các **CỘT** là measurement và **ROWS** là các transaction của business.== Do đó, 1 bảng Fact có thể lên tới trăm nghìn, triệu dòng hoặc thậm chí tỉ dòng ### Fact vs Dimension: ![](https://i.imgur.com/XspwJUB.png) ![](https://i.imgur.com/kgjMf7r.png) ![](https://i.imgur.com/1BGid1l.png) # ERP VS SAP: ![](https://i.imgur.com/kDzi7Lx.png) ERP stands for Enterprise Resource Planning **Software** that allows an organization to use a integrated applications system to manage a company’s resources efficiently and productively. SAP is name of the company as well its ERP product. # BI Business intelligence (BI) combines business analytics, data mining, data visualization, data tools and infrastructure, and best practices to help organizations to make more data-driven decision # Data Model vs Data Modeling: :::danger ==A data model== is set of the tabular data connected together by relationships. Data Model là một tổ hợp của nhiều bảng, và những bảng này liên kết với nhau bởi các relationships. ==Data modeling== is the process of creating a data model for the data to be stored in a Database. ::: # Schema: A schema is a blueprint ( ban thiet ke ) of the database. ## Type of Schema: 1. Star Schema. 1. Snow Flake Schema. 1. Galaxy Schema. (=Fact Constellation schema) A fact constellation has multiple fact tables. ![](https://i.imgur.com/khJ1bCd.png) ### Star vs Snow Flake schema: ![](https://i.imgur.com/l0mxHU3.png) ![](https://i.imgur.com/bHe4XHU.png # Data lake: Data lake là một **kho lưu trữ một lượng lớn ==dữ liệu thô== được giữ để sử dụng khi cần thiet.** ![](https://i.imgur.com/9aex07D.png) ![](https://i.imgur.com/4JiBmhS.png) ## [Data lake vs Data warehouse:](https://blog.trginternational.com/vi/phan-biet-su-khac-nhau-giua-data-lake-va-data-warehouse#:~:text=H%C3%ACnh%20th%E1%BB%A9c%20Schema,l%C3%A0%20cung%20c%E1%BA%A5p%20b%C3%A1o%20c%C3%A1o.&text=C%C3%A1ch%20ti%E1%BA%BFp%20c%E1%BA%ADn%20n%C3%A0y%20%C4%91%C6%B0%E1%BB%A3c,chi%20ph%C3%AD%20cho%20doanh%20nghi%E1%BB%87p.) to **store the big data**, the two most popular options: **data lakes and data warehouses ![](https://i.imgur.com/jXs5aja.png) ![](https://i.imgur.com/hllQuJ9.png) ### Data type **Data warehouse** cần một mô hình dữ liệu có cấu trúc rõ ràng giúp xác định các dữ liệu được lưu vào cũng như loại bỏ các dữ liệu không cần thiết. **Data lake,** tất cả các loại dữ liệu từ các nguồn của hệ thống đều được lưu trữ. Bao gồm các nguồn dữ liệu có thể bị từ chối lưu trữ trong Data warehouse, chẳng hạn như nhật ký web server, dữ liệu cảm biến, hoạt động trên mạng xã hội, văn bản và hình ảnh. ### Schema: **Data warehouse** áp dụng phương pháp **"Schema on Write"**, nghĩa là mô hình được thiết kế cho mục đích chính là cung cấp báo cáo. Quá trình này đòi hỏi đầu tư thời gian đáng kể để phân tích các nguồn dữ liệu, thấu hiểu các quy trình nghiệp vụ, phân loại dữ liệu, và hình thành một hệ thống xác định để lưu trữ dữ liệu. **Data lake** giữ dữ liệu ở trạng thái nguyên bản; khi có nhu cầu sử dụng dữ liệu để giải quyết các vấn đề kinh doanh, chỉ có những dữ liệu liên quan được chọn lọc và phân tích để đưa ra đáp án. Cách tiếp cận này được gọi là **"Schema on Read"** giúp tiết kiệm thời gian và chi phí cho doanh nghiệp. ### Scalability: Data warehouse là một kho dữ liệu có cấu trúc chặt chẽ nên việc thay đổi cấu trúc theo nhu cầu của công ty rất tốn kém. Quá trình thay đổi đòi hỏi nhiều quy trình phức tạp, mất thời gian và tốn kém. Data lake lại tận dụng tính linh hoạt của dữ liệu, bởi vì dữ liệu được lưu trữ ở dạng thô và luôn dễ dàng để truy cập, cho phép tái cấu trúc mà không có trở ngại nào.

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password
    or
    Sign in via Facebook Sign in via X(Twitter) Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    By signing in, you agree to our terms of service.

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully