<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Joy Kipkogei</title>
    <description>The latest articles on DEV Community by Joy Kipkogei (@jjoy2026).</description>
    <link>https://dev.to/jjoy2026</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4070932%2Fe5353699-a67e-42df-82f6-e83becd2603a.png</url>
      <title>DEV Community: Joy Kipkogei</title>
      <link>https://dev.to/jjoy2026</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/jjoy2026"/>
    <language>en</language>
    <item>
      <title>Power BI Technical Article : Data Modelling, Relationships &amp; Joins</title>
      <dc:creator>Joy Kipkogei</dc:creator>
      <pubDate>Wed, 30 Sep 2026 12:33:56 +0000</pubDate>
      <link>https://dev.to/jjoy2026/data-modelling-in-power-bi-flat-tables-star-schemas-and-snowflake-schemas-33g5</link>
      <guid>https://dev.to/jjoy2026/data-modelling-in-power-bi-flat-tables-star-schemas-and-snowflake-schemas-33g5</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;In today's data-driven business environment, organizations collect large amounts of information from sales systems, customer databases, financial systems, spreadsheets, and operational applications. Having lots of data is not enough, though. Organizations need to turn it into meaningful information that supports better decisions.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Power BI&lt;/strong&gt; is a business intelligence and data visualization platform developed by Microsoft. It lets you connect to different data sources, clean and transform data, build data models, create calculations, and present insights through interactive reports and dashboards.&lt;br&gt;
Power BI can connect to Excel workbooks, CSV files, databases, cloud services, and other business applications. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Power Query&lt;/strong&gt; is then used to clean and transform the data before it is loaded into the Power BI data model.&lt;/p&gt;

&lt;p&gt;Transforming data and building visuals are only part of the process. How the data is structured in the model is just as important.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why Is Data Modelling Important?
&lt;/h2&gt;

&lt;p&gt;Data modelling is the process of organizing tables, defining relationships between them, and creating a structure that allows data to be analyzed correctly. A good model matters because of:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Reporting:&lt;/strong&gt; users can easily slice and filter data using dimensions.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;DAX calculations:&lt;/strong&gt; measures become easier to write and understand.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Performance:&lt;/strong&gt; a good model reduces unnecessary duplication and supports efficient storage and querying.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Scalability:&lt;/strong&gt; the model can accommodate growing transaction volumes and additional dimensions.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Maintainability:&lt;/strong&gt; other developers and analysts can understand the model more easily.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  1. Flat Tables, Star Schemas and Snowflake Schemas
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1.1 Flat Tables
&lt;/h3&gt;

&lt;p&gt;A flat table stores information from different business entities together in a single table. Instead of separate tables for customers, products, dates, and sales, all the relevant information is stored as columns in one table.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Structure of a flat table&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fmj2qbke4t0ibwcq7kc8n.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fmj2qbke4t0ibwcq7kc8n.png" alt="Structure of a flat table" width="661" height="121"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Advantages and disadvantages of a flat table&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Advantages&lt;/th&gt;
&lt;th&gt;Disadvantages&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Simple to understand and build&lt;/td&gt;
&lt;td&gt;Repeats descriptive values on every row&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;No relationships to manage&lt;/td&gt;
&lt;td&gt;Wide tables with many high-cardinality columns&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Fast to prototype&lt;/td&gt;
&lt;td&gt;Slower refresh and harder maintenance as data grows&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Fine for small datasets&lt;/td&gt;
&lt;td&gt;Hard to share dimensions across multiple fact tables&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Appropriate use:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Small, simple datasets&lt;/li&gt;
&lt;li&gt;One-off or ad hoc analysis&lt;/li&gt;
&lt;li&gt;Datasets with no repeating relationships&lt;/li&gt;
&lt;li&gt;Prototypes or personal dashboards&lt;/li&gt;
&lt;li&gt;Data that already arrives flat&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  1.2 Star Schema
&lt;/h3&gt;

&lt;p&gt;A star schema is a modelling pattern that organizes data into one central &lt;strong&gt;fact table&lt;/strong&gt; (the transactions: sales, orders, events) surrounded by several &lt;strong&gt;dimension tables&lt;/strong&gt; (the descriptive attributes: who, what, where, when). It is the recommended pattern for Power BI models.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Fact table (center):&lt;/strong&gt; contains quantitative data.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Dimension tables (points):&lt;/strong&gt; contain descriptive attributes.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;Structure of a star schema&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fq7421h3a625owayugpiy.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fq7421h3a625owayugpiy.png" alt="Structure of a star schema" width="800" height="588"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Advantages and disadvantages of a star schema&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Advantages&lt;/th&gt;
&lt;th&gt;Disadvantages&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Simple, intuitive structure&lt;/td&gt;
&lt;td&gt;Requires upfront design effort&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Fast, predictable queries&lt;/td&gt;
&lt;td&gt;Needs data preparation to split source data into facts and dimensions&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Easy to write DAX against&lt;/td&gt;
&lt;td&gt;Some denormalization inside dimensions&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Shared dimensions across reports&lt;/td&gt;
&lt;td&gt;Not needed for tiny, one-off datasets&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Appropriate use of a star schema:&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;BI analysts and report developers building Power BI, Tableau, or other dashboards on recurring, growing datasets.&lt;/li&gt;
&lt;li&gt;Data warehouse and data engineering teams designing the backend structure that feeds reporting tools.&lt;/li&gt;
&lt;li&gt;Organizations with multiple related datasets (sales, inventory, finance) that want shared, consistent dimensions across reports.&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  1.3 Snowflake Schema
&lt;/h3&gt;

&lt;p&gt;A snowflake schema takes the star schema one step further. Instead of stopping at a single table per dimension, the dimensions themselves are &lt;strong&gt;normalized into sub-tables&lt;/strong&gt; (for example, Product → Subcategory → Category).&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Structure of a snowflake schema&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fht9tymz4v07ueoapzwp2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fht9tymz4v07ueoapzwp2.png" alt="Structure of a snowflake schema" width="800" height="694"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Advantages and disadvantages of a snowflake schema&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Frc186kkn0fztt7haljbh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Frc186kkn0fztt7haljbh.png" alt=" " width="743" height="193"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Fact Tables and Dimension Tables
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Fact table:&lt;/strong&gt; contains quantitative, measurable data (for example, revenue and quantity sold) alongside foreign keys that link to the dimension tables.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Dimension tables:&lt;/strong&gt; contain descriptive attributes or context about the facts (for example, customer names, product categories, store locations).&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Numeric columns vs. descriptive attributes
&lt;/h3&gt;

&lt;p&gt;Numeric fact columns such as &lt;strong&gt;Quantity&lt;/strong&gt; and &lt;strong&gt;Sales Amount&lt;/strong&gt; are additive: they can be summed, averaged, or compared over time. In Power BI you aggregate them with &lt;strong&gt;DAX measures&lt;/strong&gt; such as &lt;code&gt;Total Sales = SUM(Sales[Sales Amount])&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Descriptive attributes (Customer Name, Product Name, Category, Location, Date) are not aggregated. They are used to filter, group, or label the numbers. This is why numeric values live in the fact table and descriptive attributes live in dimension tables.&lt;/p&gt;

&lt;h3&gt;
  
  
  Grain
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Grain&lt;/strong&gt; defines exactly what one row in the fact table represents. For example, &lt;em&gt;"one row per order line"&lt;/em&gt; or &lt;em&gt;"one row per product per store per day."&lt;/em&gt; Decide the grain first, because every column in the fact table must be true at that level of detail.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fb4be51ox02vxjfuiphez.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fb4be51ox02vxjfuiphez.png" alt="Fact and dimension table example 1" width="630" height="169"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ft5k8lpk0u0s85gf0ewep.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ft5k8lpk0u0s85gf0ewep.png" alt="Fact and dimension table example 2" width="230" height="145"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fy9jygwwde074yhudjcxg.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fy9jygwwde074yhudjcxg.png" alt="Fact and dimension table example 3" width="310" height="241"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F1nu7dpeh2hptrd99s4i5.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F1nu7dpeh2hptrd99s4i5.png" alt="Fact and dimension table example 4" width="230" height="121"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fpha7k475ran4a28qdgjy.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fpha7k475ran4a28qdgjy.png" alt="Fact and dimension table example 5" width="470" height="121"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Relationships in Power BI
&lt;/h2&gt;

&lt;p&gt;A relationship is established by matching the &lt;strong&gt;primary key&lt;/strong&gt; in a dimension table to the corresponding &lt;strong&gt;foreign key&lt;/strong&gt; in the fact table. Power BI stores data in separate tables, so without a relationship those tables have no way of knowing how they relate.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Key terms&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Cardinality:&lt;/strong&gt; describes how rows in one table relate to rows in another, based on the count of matching rows.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Primary key:&lt;/strong&gt; a column that uniquely identifies each row in a table.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Foreign key:&lt;/strong&gt; a column that references the primary key of another table.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Relationship cardinalities
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;One-to-many (1:*)&lt;/strong&gt;: a single row in the "one" table matches many rows in the "many" table. Example: one Customer → many Sales rows.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;One-to-one (1:1)&lt;/strong&gt;: each row in Table A links to exactly one row in Table B, and vice versa. Both sides need unique keys.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Many-to-many (*:*)&lt;/strong&gt;: rows in Table A can match multiple rows in Table B and vice versa, because neither side has unique values in the key column.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Feeu5ymv3ejw4e46oll1x.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Feeu5ymv3ejw4e46oll1x.png" alt="Relationship cardinalities" width="800" height="607"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  4. Filter Direction
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Single-direction filtering
&lt;/h3&gt;

&lt;p&gt;Filters flow only from the "one" side of the relationship (usually the dimension table) to the "many" side (usually the fact table). Filters do not flow in the opposite direction.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt; selecting a Category in a slicer filters the Sales table, but selecting a Sales row does not filter the Category table.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Flqmk3miu0789128wt9ne.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Flqmk3miu0789128wt9ne.png" alt="Single direction filtering" width="800" height="425"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Both (bidirectional) filtering
&lt;/h3&gt;

&lt;p&gt;The filter direction is set to &lt;strong&gt;Both&lt;/strong&gt;, so filters travel from the dimension to the fact table and from the fact table back to the dimension.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F707jg6kuzmjr3yxp94z2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F707jg6kuzmjr3yxp94z2.png" alt="Bidirectional filtering" width="739" height="479"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Advantages&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;More flexible filtering across related tables.&lt;/li&gt;
&lt;li&gt;Useful in some complex reporting scenarios.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Considerations&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Can create ambiguous filter paths.&lt;/li&gt;
&lt;li&gt;May cause unintended cross-filtering between tables.&lt;/li&gt;
&lt;li&gt;Can make the model more complex and hurt performance.&lt;/li&gt;
&lt;li&gt;For many-to-many scenarios, a &lt;strong&gt;bridge table&lt;/strong&gt; with single-direction relationships is usually a safer solution than bidirectional filtering.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  5. Joins in Power Query
&lt;/h2&gt;

&lt;p&gt;A join combines two tables by matching values in key columns. In the Power Query interface this operation is called &lt;strong&gt;Merge Queries&lt;/strong&gt;. The join type decides which rows are kept.&lt;/p&gt;

&lt;h3&gt;
  
  
  Inner Join
&lt;/h3&gt;

&lt;p&gt;Keeps only records that have matching values in &lt;strong&gt;both&lt;/strong&gt; tables.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ffjb9y9l6lxr9ib8l74qa.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ffjb9y9l6lxr9ib8l74qa.png" alt="Inner join" width="800" height="623"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Left Outer Join
&lt;/h3&gt;

&lt;p&gt;Keeps &lt;strong&gt;all rows from the left (first) table&lt;/strong&gt; and only the matching rows from the right (second) table. Unmatched left rows get nulls in the columns from the right table.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F7y7i4t589n38ru2tm649.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F7y7i4t589n38ru2tm649.png" alt="Left outer join" width="800" height="644"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Right Outer Join
&lt;/h3&gt;

&lt;p&gt;Keeps &lt;strong&gt;all rows from the right (second) table&lt;/strong&gt; and only the matching rows from the left (first) table.&lt;/p&gt;

&lt;h3&gt;
  
  
  Full Outer Join
&lt;/h3&gt;

&lt;p&gt;Keeps &lt;strong&gt;all records from both tables&lt;/strong&gt;, whether or not a match exists.&lt;/p&gt;

&lt;h3&gt;
  
  
  Left Anti Join
&lt;/h3&gt;

&lt;p&gt;Keeps only the rows from the left table that have &lt;strong&gt;no match&lt;/strong&gt; in the right table.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fb4f2qex9scf06bg7iqmo.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fb4f2qex9scf06bg7iqmo.png" alt="Left anti join" width="800" height="644"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Right Anti Join
&lt;/h3&gt;

&lt;p&gt;Keeps only the rows from the right table that have &lt;strong&gt;no match&lt;/strong&gt; in the left table.&lt;/p&gt;

&lt;p&gt;Both Power Query joins and Power BI relationships connect data from multiple tables, but they serve different purposes and happen at different stages of the workflow.&lt;/p&gt;

&lt;h2&gt;
  
  
  6. Power Query Joins vs Power BI Relationships
&lt;/h2&gt;

&lt;h3&gt;
  
  
  What is a Power Query merge?
&lt;/h3&gt;

&lt;p&gt;A merge combines data from two or more tables during the &lt;strong&gt;data preparation stage&lt;/strong&gt;, before the data is loaded into the model. Power Query physically brings columns from one table into another based on matching values.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Sales table&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;SalesID&lt;/th&gt;
&lt;th&gt;ProductID&lt;/th&gt;
&lt;th&gt;Quantity&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;1001&lt;/td&gt;
&lt;td&gt;P01&lt;/td&gt;
&lt;td&gt;5&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;1002&lt;/td&gt;
&lt;td&gt;P02&lt;/td&gt;
&lt;td&gt;3&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Products table&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;ProductID&lt;/th&gt;
&lt;th&gt;ProductName&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;P01&lt;/td&gt;
&lt;td&gt;Laptop&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;P02&lt;/td&gt;
&lt;td&gt;Mouse&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;After a Left Outer Join:&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;SalesID&lt;/th&gt;
&lt;th&gt;ProductID&lt;/th&gt;
&lt;th&gt;Quantity&lt;/th&gt;
&lt;th&gt;ProductName&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;1001&lt;/td&gt;
&lt;td&gt;P01&lt;/td&gt;
&lt;td&gt;5&lt;/td&gt;
&lt;td&gt;Laptop&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;1002&lt;/td&gt;
&lt;td&gt;P02&lt;/td&gt;
&lt;td&gt;3&lt;/td&gt;
&lt;td&gt;Mouse&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Does a merge physically combine data?&lt;/strong&gt; Yes. It copies columns from one table into another.&lt;/p&gt;

&lt;h3&gt;
  
  
  What is a Power BI relationship?
&lt;/h3&gt;

&lt;p&gt;A relationship connects tables &lt;strong&gt;within the model&lt;/strong&gt; without physically combining them. The tables remain separate, and Power BI uses the relationship to let filters and calculations flow between them during analysis.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fq810q5qyoecgpvj0cxkm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fq810q5qyoecgpvj0cxkm.png" alt="Power BI relationship example" width="800" height="452"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Does creating a relationship combine tables?&lt;/strong&gt; No. Relationships do not copy, append, or merge data. They only define how tables interact.&lt;/p&gt;

&lt;h3&gt;
  
  
  Where each one happens in the workflow
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Data Sources
     ↓
Power Query        ← merges happen here
     ↓
Load Data
     ↓
Data Model         ← relationships are created here
     ↓
Reports
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  When to use a merge
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;You need additional columns in a single table.&lt;/li&gt;
&lt;li&gt;You are cleansing or enriching data.&lt;/li&gt;
&lt;li&gt;You are working with small datasets.&lt;/li&gt;
&lt;li&gt;You are preparing staging tables before modelling.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  When to use a relationship
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;You are building a star schema.&lt;/li&gt;
&lt;li&gt;You are working with large datasets.&lt;/li&gt;
&lt;li&gt;You are creating scalable BI solutions.&lt;/li&gt;
&lt;li&gt;Multiple fact tables need to share common dimensions.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  How excessive merging affects a data model
&lt;/h3&gt;

&lt;p&gt;Excessive merging tends to produce one large flat table full of repeated values such as Customer Name, Product Name, Region, and Category. This can lead to:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Increased model size and memory consumption&lt;/li&gt;
&lt;li&gt;Wider tables with many high-cardinality columns&lt;/li&gt;
&lt;li&gt;Slower refresh times&lt;/li&gt;
&lt;li&gt;Harder maintenance&lt;/li&gt;
&lt;li&gt;Ambiguity when several fact tables need the same dimensions&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Why keep fact and dimension tables separate?
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Reduced redundancy:&lt;/strong&gt; dimension information is stored once instead of thousands of times.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Better performance:&lt;/strong&gt; smaller dimension tables filter faster and keep the model lean.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Easier DAX:&lt;/strong&gt; measures work against clean fact columns, and slicers use clean dimension columns.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Improved scalability:&lt;/strong&gt; you can add new fact and dimension tables without redesigning the model.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Better readability:&lt;/strong&gt; developers can clearly see what is being measured (facts) and how it is categorized (dimensions).&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Practical business example
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Merge approach:&lt;/strong&gt; a company merges Sales, Customers, Products, and Regions into a single table of one million rows. Every row repeats customer, product, and region details.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Result:&lt;/em&gt; larger model, more redundancy, lower performance.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Relationship approach:&lt;/strong&gt; separate tables are kept and connected by relationships.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Fact Sales&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Customer Key&lt;/th&gt;
&lt;th&gt;Product Key&lt;/th&gt;
&lt;th&gt;Region Key&lt;/th&gt;
&lt;th&gt;Date Key&lt;/th&gt;
&lt;th&gt;Sales Amount&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;1&lt;/td&gt;
&lt;td&gt;10&lt;/td&gt;
&lt;td&gt;100&lt;/td&gt;
&lt;td&gt;20260101&lt;/td&gt;
&lt;td&gt;250&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Dim Customer&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Customer Key&lt;/th&gt;
&lt;th&gt;Customer Name&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;1&lt;/td&gt;
&lt;td&gt;Amina Otieno&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Dim Product&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Product Key&lt;/th&gt;
&lt;th&gt;Product Name&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;10&lt;/td&gt;
&lt;td&gt;Laptop&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Dim Region&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Region Key&lt;/th&gt;
&lt;th&gt;Region&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;100&lt;/td&gt;
&lt;td&gt;Nairobi&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Dim Date&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Date Key&lt;/th&gt;
&lt;th&gt;Date&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;20260101&lt;/td&gt;
&lt;td&gt;2026-01-01&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;em&gt;Result:&lt;/em&gt; smaller model, better performance, easier maintenance, greater scalability.&lt;/p&gt;

&lt;h2&gt;
  
  
  7. Recommended Power BI Model
&lt;/h2&gt;

&lt;p&gt;For most business intelligence projects, I recommend a &lt;strong&gt;star schema with one-to-many relationships and single-direction filtering&lt;/strong&gt;, based on performance, maintainability, scalability, and ease of report development.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why not a flat table?
&lt;/h3&gt;

&lt;p&gt;Flat tables are easy to understand, but they become hard to maintain as datasets grow:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;High data redundancy&lt;/li&gt;
&lt;li&gt;Larger model sizes&lt;/li&gt;
&lt;li&gt;Slower refresh&lt;/li&gt;
&lt;li&gt;Poor scalability&lt;/li&gt;
&lt;li&gt;Difficult maintenance&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;They suit small prototypes but are generally not ideal for enterprise BI solutions.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why not a snowflake schema?
&lt;/h3&gt;

&lt;p&gt;Snowflaking saves a little storage but adds more tables, more relationships, and longer filter paths. In Power BI, dimension tables are usually small, so the storage saving is minor. The cost is a model that is harder to navigate and slower to query. Unless a source system forces it, flatten sub-dimensions into a single dimension table (the Product table carries Subcategory and Category).&lt;/p&gt;

&lt;h3&gt;
  
  
  Best practices to go with the star schema
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Use a dedicated Date table&lt;/strong&gt; and mark it as a date table.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Hide foreign keys&lt;/strong&gt; in the fact table so report authors use dimension columns.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Use role-playing dimensions&lt;/strong&gt; when one dimension plays several roles (for example, Order Date and Ship Date both link to Dim Date).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Understand active vs inactive relationships:&lt;/strong&gt; only one relationship between two tables can be active. Use &lt;code&gt;USERELATIONSHIP()&lt;/code&gt; in DAX to activate an inactive one.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Prefer single-direction filtering&lt;/strong&gt; and avoid bidirectional filters unless truly necessary.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Conclusion and Key Takeaways
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Data modelling is as important as data transformation and visualization.&lt;/li&gt;
&lt;li&gt;Flat tables are fine for quick prototypes but do not scale.&lt;/li&gt;
&lt;li&gt;Star schemas are the recommended pattern for Power BI: fast, simple, and easy to maintain.&lt;/li&gt;
&lt;li&gt;Snowflake schemas add complexity that rarely pays off in Power BI.&lt;/li&gt;
&lt;li&gt;Use &lt;strong&gt;Power Query merges&lt;/strong&gt; for data preparation and &lt;strong&gt;relationships&lt;/strong&gt; for modelling.&lt;/li&gt;
&lt;li&gt;Keep facts and dimensions separate, define the grain, and use one-to-many relationships with single-direction filters.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;A well-built model makes every report, measure, and refresh easier for you and for the next person who inherits it.&lt;/p&gt;

</description>
      <category>datascience</category>
      <category>bigdata</category>
    </item>
    <item>
      <title>My First GitHub Project:From a Local Folder to GitHub Using Git and SSH</title>
      <dc:creator>Joy Kipkogei</dc:creator>
      <pubDate>Sun, 23 Aug 2026 05:10:16 +0000</pubDate>
      <link>https://dev.to/jjoy2026/my-first-github-projectfrom-a-local-folder-to-github-using-git-and-ssh-42ob</link>
      <guid>https://dev.to/jjoy2026/my-first-github-projectfrom-a-local-folder-to-github-using-git-and-ssh-42ob</guid>
      <description>&lt;p&gt;As someone who works with reports and data, with completely zero experience in data analytics and data science, Git and GitHub initially felt unfamiliar to me. I was used to working with documents, spreadsheets, reports, and data, but I had never used version control or the command line before.&lt;/p&gt;

&lt;p&gt;As I started learning Git and GitHub, I realized that these tools can help me organize, track, and manage data-related projects. I decided to put what I learned into practice by creating a simple personal project and taking it from a local folder on my computer to GitHub using Git and SSH.&lt;/p&gt;

&lt;p&gt;Rather than just documenting the commands, this article shares what I actually did, what each step means, the challenges I encountered, and what I learned along the way.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;Introduction to Git and Git Hub&lt;/em&gt;&lt;/strong&gt;&lt;br&gt;
Git - A version control system that tracks changes to files and keeps a history of those changes as projects develop.&lt;br&gt;
GitHub- A cloud-based platform that hosts Git repositories and allows people to store, manage, share, and collaborate on projects.&lt;br&gt;
&lt;strong&gt;_Comparison of the two : _&lt;/strong&gt;&lt;br&gt;
&lt;em&gt;Git is the tool that tracks changes in your project, while GitHub is the online platform where you can store and share that project&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;Step 1: Installing the Required Tools and Applications&lt;/em&gt;&lt;/strong&gt;&lt;br&gt;
Before starting my project, I first installed and prepared the tools required to work with Git and GitHub.&lt;br&gt;
The main tools I needed were Git, Git Bash, Visual Studio Code (VS Code), and a GitHub account&lt;br&gt;
&lt;em&gt;&lt;strong&gt;Step 2: Setting Up Git and Creating an SSH Key&lt;/strong&gt;&lt;/em&gt;&lt;br&gt;
After installing Git, I opened Git Bash, which provides a command-line interface for interacting with Git and navigating files on my computer.&lt;br&gt;
I then configured my Git identity using my name and email address.&lt;br&gt;
After configuring Git, the next step was to connect my local computer to GitHub. I generated an SSH key using Git Bash and then added my public key to my GitHub account. This allowed me to establish a secure connection between my local Git environment and GitHub.&lt;br&gt;
&lt;em&gt;&lt;strong&gt;Step 3: Creating a project folder&lt;/strong&gt;&lt;/em&gt;&lt;br&gt;
I created a folder by running this commands:&lt;br&gt;
Run &lt;code&gt;pwd&lt;/code&gt;- to confirm location&lt;br&gt;
Run &lt;code&gt;ls&lt;/code&gt; - to see folders available&lt;br&gt;
Run &lt;code&gt;cd "Desktop"&lt;/code&gt;- the chosen location to create the project folder&lt;br&gt;
Run &lt;code&gt;ls&lt;/code&gt; - to check content of the Desktop folder&lt;br&gt;
Run &lt;code&gt;mkdir my-data-project&lt;/code&gt; - to create folder&lt;br&gt;
&lt;em&gt;&lt;strong&gt;Step 4: Create files inside the project folder&lt;/strong&gt;&lt;/em&gt;&lt;br&gt;
I created three subfolders to organize my project: Data, Scripst and notebooks&lt;br&gt;
run &lt;code&gt;mkdir data&lt;/code&gt;&lt;br&gt;
run &lt;code&gt;mkdir scripts&lt;/code&gt;&lt;br&gt;
run &lt;code&gt;mkdir notebook&lt;/code&gt;&lt;br&gt;
run &lt;code&gt;touch README.md&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;&lt;em&gt;Step 5: Add content to the file folders&lt;/em&gt;&lt;/strong&gt;&lt;br&gt;
For README file&lt;br&gt;
run &lt;code&gt;code README.md&lt;/code&gt;&lt;br&gt;
This opened the file in VS Code, where I added information about the project, its purpose, and the project structure.&lt;br&gt;
For data file&lt;br&gt;
I copied the data received in class and pasted in the folder&lt;br&gt;
then run ls of the data folder to see the data file uploaded&lt;br&gt;
&lt;em&gt;&lt;strong&gt;Step 6: Add and Commit Files&lt;/strong&gt;&lt;/em&gt;&lt;br&gt;
Check Git status:&lt;br&gt;
run &lt;code&gt;git status&lt;/code&gt;&lt;br&gt;
Stage all project files:&lt;br&gt;
run&lt;code&gt;git add .&lt;/code&gt;&lt;br&gt;
Create the first commit:&lt;br&gt;
run &lt;code&gt;git commit -m "Initial project setup"&lt;/code&gt;&lt;br&gt;
Verify:&lt;br&gt;
run &lt;code&gt;git status&lt;/code&gt;&lt;br&gt;
&lt;em&gt;&lt;strong&gt;Step 7: Creating a a GitHub Repository&lt;/strong&gt;&lt;/em&gt;&lt;br&gt;
Open GitHub&lt;br&gt;
Create a newrepository and name it Kenya-Hospital-Records-2&lt;br&gt;
Copy the ssh code generated and run it on Gitbash&lt;br&gt;
Check the connection by running &lt;code&gt;git remote -v&lt;/code&gt;&lt;br&gt;
Run &lt;code&gt;git branch -M main&lt;/code&gt; - to rename branch to main&lt;br&gt;
Run &lt;code&gt;git push -u origin main&lt;/code&gt; to push the project to GitHub&lt;br&gt;
The git push command uploads my local commits to the remote repository. origin refers to my GitHub repository, while main is the branch I am pushing.&lt;br&gt;
The project was added successfuly: &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F93toout49d44h6ffk44a.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F93toout49d44h6ffk44a.png" alt=" " width="800" height="169"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;&lt;strong&gt;Challenges I encountered as a first time using Git and Gitbash&lt;/strong&gt;&lt;/em&gt;&lt;br&gt;
• Navigating folders using Git Bash.&lt;br&gt;
• Understanding Git commands.&lt;br&gt;
• Setting up SSH authentication.&lt;br&gt;
• Connecting the local repository to GitHub.&lt;br&gt;
&lt;strong&gt;_  What I learned _&lt;/strong&gt;&lt;br&gt;
This practical exercise helped me understand how Git and GitHub work together. I learned how to create a local project, organize files, initialize a Git repository, stage and commit changes, create an SSH connection, connect my local repository to GitHub, and push my project online.&lt;br&gt;
More importantly, I learned that Git is not just about memorizing commands. Understanding what each command does makes it easier to troubleshoot errors and manage projects effectively. As I continue learning data analytics and data science, I can see how Git and GitHub will help me organize my projects and track my work over time.&lt;/p&gt;

</description>
      <category>git</category>
      <category>github</category>
      <category>datascience</category>
      <category>luxdev</category>
    </item>
  </channel>
</rss>
