<?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: Erasto Wamuti</title>
    <description>The latest articles on DEV Community by Erasto Wamuti (@erasto).</description>
    <link>https://dev.to/erasto</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.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3709803%2F3ea648d8-aa8f-4a0a-b534-3e9f4f0385e0.png</url>
      <title>DEV Community: Erasto Wamuti</title>
      <link>https://dev.to/erasto</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/erasto"/>
    <language>en</language>
    <item>
      <title>Understanding How AI Agents Work</title>
      <dc:creator>Erasto Wamuti</dc:creator>
      <pubDate>Thu, 19 Mar 2026 16:23:55 +0000</pubDate>
      <link>https://dev.to/erasto/understanding-how-ai-agents-work-2bb4</link>
      <guid>https://dev.to/erasto/understanding-how-ai-agents-work-2bb4</guid>
      <description>&lt;p&gt;&lt;strong&gt;Automation&lt;/strong&gt; has been at the forefront of improving productivity and output in industry. Such technologies have been developed, and &lt;strong&gt;automation&lt;/strong&gt; has always been at the forefront of improving productivity and output in industry. Such technologies have been developed and embraced in a world where human effort is slowly being directed into intelligent decision-making and tough system design questions. In the AI age we are living in, it is not a surprise that the most fascinating use cases have been in the automation of processes and repetitive tasks.braced in a world where human effort is slowly being directed into intelligent decision-making and tough system design questions. In the AI age we are living in, it is not a surprise that the most fascinating use cases have been in the automation of processes and repetitive tasks.&lt;/p&gt;

&lt;p&gt;💻&lt;/p&gt;

&lt;p&gt;The use of &lt;strong&gt;large language models(LLMs)&lt;/strong&gt; has been the most adopted in AI models among the general population. Whether you are a student at school doing research, an online shopper trying to find product comparisons, or an engineer brainstorming for a solution, the list is endless.&lt;/p&gt;

&lt;p&gt;The next step in the evolution of &lt;strong&gt;LLM&lt;/strong&gt; models is using them to perform actions and training them for specific use cases. This has given rise to AI agents. That takes us to the question: so what is an agent?&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;An &lt;strong&gt;agent&lt;/strong&gt; is a person who takes actions on behalf of another. For example, if you were handling a car sales business, you could appoint two or more people who would engage with customers and sell the cars in stock. The business is yours, but the sales were done by sales agents. Usually, there are specific guidelines that they have to follow so that they can qualify for a sales role. They need to be good at communication skills, know the car models and prices, and the business processes involved. The same can be said of an AI agent.&lt;/p&gt;
&lt;/blockquote&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.amazonaws.com%2Fuploads%2Farticles%2Fbp7virklwe8jxkjkg5ft.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.amazonaws.com%2Fuploads%2Farticles%2Fbp7virklwe8jxkjkg5ft.png" alt="car-salesman" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;An AI assistant/agent&lt;/strong&gt; is a type of software that is used to do tasks on behalf of a human being. The normal routine of a working person may involve: daily exercise, reading books, riding to work, getting home, evening routines, and resting. Automation in this case would be woven into these daily tasks to aid in decluttering the person’s tasks. An AI assistant once installed in the user’s phone could read the emails and sound a beep to notify the user of an urgent message, book gym sessions on behalf of the user, track the payments the user has on the text message, etc.&lt;/p&gt;

&lt;p&gt;AI agents do this by synthesizing user input or instructions and performing actions using coded functions and interconnected services on &lt;strong&gt;APIs&lt;/strong&gt;. In this way, when a user does one prompt, the effect is felt in three more applications as a result.&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.amazonaws.com%2Fuploads%2Farticles%2Ftohqkqdal7jv4g7dnmvu.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.amazonaws.com%2Fuploads%2Farticles%2Ftohqkqdal7jv4g7dnmvu.png" alt="AI-agent" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;For this to be achieved, the agent executes actions by incorporating relevant tools. Different agents are designed for different tasks and can differ in design and makeup, but what unites them all is that they use Artificial Intelligence models to synthesize their inputs, whether from user input or &lt;strong&gt;API&lt;/strong&gt; responses, and execute the next sequence as instructed. While an AI model can give back responses when prompted, an agent processes the prompt, gets the responses, and then performs the execution step if included in the instruction. The other benefit is that an AI agent can get results and correct itself till the right output is achieved.&lt;/p&gt;

&lt;h2&gt;
  
  
  Makeup and Design of an AI Agent
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;The Core(Thinking Engine)&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;This is the part that processes prompts, gets meaning, and gets actions from user input. An agent does this by calling on a Large Language Model to process inputs. That means an agent has to be connected to an LLM model through an API key. &lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Context&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;This part stores the user's history in the conversation to determine context and refer to it for relevant answers.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Tools&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The agent is equipped with tools that help it perform actions when triggered. This could be a web scraper that is called to crawl through websites for information, pdf scanner, etc. The tools are called upon demand, and agents are set up with these tools depending on the tasks that the agent will carry out &lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Loop&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;This is the step that allows an agent to check for errors, correct itself, and repeat execution of different file paths till it gets to the expected output. &lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;AI agents represent a significant leap forward in how we interact with and benefit from artificial intelligence. They combine a thinking engine, contextual memory, purpose-built tools, and a self-correcting loop. As these agents become more sophisticated and more deeply integrated into our daily processes and routines, the line between using a tool and delegating a task will continue to blur. The vision is clearly a future where humans focus on creativity, strategy, and connection, while AI agents handle the repetitive, time-consuming work in the background.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>beginners</category>
      <category>agents</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Integrating PostgreSQL with Power BI for Data Analysis</title>
      <dc:creator>Erasto Wamuti</dc:creator>
      <pubDate>Fri, 13 Mar 2026 06:55:27 +0000</pubDate>
      <link>https://dev.to/erasto/integrating-postgresql-with-power-bi-for-data-analysis-11lm</link>
      <guid>https://dev.to/erasto/integrating-postgresql-with-power-bi-for-data-analysis-11lm</guid>
      <description>&lt;p&gt;Power BI is a business intelligence tool made for extracting, organizing, and visualizing data in business. The goal is to take raw data and get insights after processing and analysis. Data can be in various forms, such as spreadsheets, databases, cloud-hosted files, and more.&lt;/p&gt;

&lt;h2&gt;
  
  
  Databases
&lt;/h2&gt;

&lt;p&gt;In the past, organizations stored data in files and folders, but now other forms of data storage are favored. Technological improvements have made applications mainstream in business, and data storage has changed significantly alongside them. The modern business landscape demands real-time data access, concurrent collaboration, and structured storage solutions. The need for database storage cannot be ignored. Databases offer ease of access, security, and concurrency.&lt;/p&gt;

&lt;p&gt;Databases are categorized depending on the structure they use to store data:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Structured Query Language (SQL):&lt;/strong&gt; Use relational tables to store information. Examples: MySQL, PostgreSQL.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No-SQL (Non-relational):&lt;/strong&gt; Use other means such as JSON, objects, etc. Examples: Redis, MongoDB.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;SQL-based databases are ideal for working with structured data that can be combined through relationships. They enable data cleaning and processing to produce accurate data, which is later used for analysis.&lt;/p&gt;

&lt;h3&gt;
  
  
  Connecting Power BI to a Local Postgres Database
&lt;/h3&gt;

&lt;p&gt;Postgres is a structured query database and is used to develop modern applications and online systems. As we have seen, there are various data sources such as Excel files, CSV files, database files, cloud storage, etc. Power BI is capable of importing and loading the data from these sources.&lt;/p&gt;

&lt;h3&gt;
  
  
  Database Connections
&lt;/h3&gt;

&lt;p&gt;Database systems can be hosted on:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Local servers&lt;/strong&gt;: the computer a user is operating (localhost)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Online database services&lt;/strong&gt;: such as AWS, GCP, Aiven, DB Clusters, etc.&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.amazonaws.com%2Fuploads%2Farticles%2F5qn7bxnxqmzijijin6ws.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.amazonaws.com%2Fuploads%2Farticles%2F5qn7bxnxqmzijijin6ws.png" alt="companies with online database services" width="800" height="436"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Connecting Power BI to a locally hosted Database
&lt;/h3&gt;

&lt;p&gt;Here are the steps to connecting your Power BI to a locally hosted Postgres database and importing data:&lt;/p&gt;

&lt;p&gt;a. Open Power BI and select Get Data on the topbar menu.&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.amazonaws.com%2Fuploads%2Farticles%2F22xbujfbc3p4r5gt3nhe.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.amazonaws.com%2Fuploads%2Farticles%2F22xbujfbc3p4r5gt3nhe.png" alt="get data from sql" width="800" height="437"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;b. Scroll through the list of sources and click more options. Select databases and the corresponding PostgreSQL DB on the right and connect.&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.amazonaws.com%2Fuploads%2Farticles%2Fcaokqcr3jqky2zm5bi63.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.amazonaws.com%2Fuploads%2Farticles%2Fcaokqcr3jqky2zm5bi63.png" alt="database connection" width="800" height="513"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;c. Enter the server as localhost and the name of the database you are connecting to.&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.amazonaws.com%2Fuploads%2Farticles%2Fffrnesibzhhe92jdn0bt.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.amazonaws.com%2Fuploads%2Farticles%2Fffrnesibzhhe92jdn0bt.png" alt="hostname" width="800" height="461"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;d. Provide the name and the password to the database.&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.amazonaws.com%2Fuploads%2Farticles%2Fnj5v4et65thxudn8mnvp.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.amazonaws.com%2Fuploads%2Farticles%2Fnj5v4et65thxudn8mnvp.png" alt="password" width="800" height="413"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;e. Once the connection is successful, Power BI loads all the tables you have created in the database. Select the tables you wish to work on and load the data.&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.amazonaws.com%2Fuploads%2Farticles%2Fjw4b738rzpb6d1kaf6kt.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.amazonaws.com%2Fuploads%2Farticles%2Fjw4b738rzpb6d1kaf6kt.png" alt="load data" width="800" height="638"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;f. You can open the Power query to check for data consistency and correct any errors in the data. &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.amazonaws.com%2Fuploads%2Farticles%2F8ah07s5irpwp0ynoto3a.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.amazonaws.com%2Fuploads%2Farticles%2F8ah07s5irpwp0ynoto3a.png" alt="power-query" width="800" height="401"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;h. Once the cleaning is done you can create a relationship between the tables using the common column(id) between them. Open the model view and inspect the relationship between the 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.amazonaws.com%2Fuploads%2Farticles%2Fiyhek7a0qzlu6ph9ypfk.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.amazonaws.com%2Fuploads%2Farticles%2Fiyhek7a0qzlu6ph9ypfk.png" alt="table-relationships" width="800" height="441"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Connecting Power BI to a Cloud PostgreSQL Database (Aiven)
&lt;/h3&gt;

&lt;p&gt;It is standard practice for online servers that host databases to establish security protocols. As such, to connect Power BI to a database hosted on a cloud service, you have to establish a secure connection. This is achieved by the use of an encryption certificate that encrypts data from your computer, and the server only responds by decrypting the message using the encryption rules. Only the computer that has this certificate can connect to the server.&lt;/p&gt;

&lt;h4&gt;
  
  
  Part 1: Connect to Database Server
&lt;/h4&gt;

&lt;p&gt;For our case, the Aiven cloud service that hosts our database has all these details.&lt;br&gt;
Follow these steps to connect your Power BI to Aiven:&lt;/p&gt;

&lt;p&gt;a. Select the database service in Aiven you wish to connect to and activate it. In this case, the &lt;strong&gt;PostgreSQL Database&lt;/strong&gt; service.  Click the &lt;strong&gt;Service Overview&lt;/strong&gt; to display the service details.&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.amazonaws.com%2Fuploads%2Farticles%2F2i8zmo0iog9rhc6qkq49.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.amazonaws.com%2Fuploads%2Farticles%2F2i8zmo0iog9rhc6qkq49.png" alt="aiven dashboard" width="800" height="374"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;b. Click the &lt;strong&gt;Download&lt;/strong&gt; button on the CA Certificate and save it to your PC.&lt;/p&gt;

&lt;p&gt;c. Rename the downloaded file from &lt;code&gt;ca.pem&lt;/code&gt; to &lt;code&gt;ca.crt&lt;/code&gt;.&lt;br&gt;
d.Double-click the &lt;code&gt;ca.crt&lt;/code&gt; file and click &lt;strong&gt;Install Certificate&lt;/strong&gt; on your PC.&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.amazonaws.com%2Fuploads%2Farticles%2F4kirmz2pg0dufgiav6xz.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.amazonaws.com%2Fuploads%2Farticles%2F4kirmz2pg0dufgiav6xz.png" alt="install ca certificate" width="503" height="642"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;e. Select &lt;strong&gt;Local Machine&lt;/strong&gt; as the installation location.&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.amazonaws.com%2Fuploads%2Farticles%2F00hpuapng0aci7xibps3.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.amazonaws.com%2Fuploads%2Farticles%2F00hpuapng0aci7xibps3.png" alt="location on pc-machine" width="666" height="648"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;f.Select the certificate store: choose &lt;strong&gt;Trusted Root Certification Authorities&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.amazonaws.com%2Fuploads%2Farticles%2F2wf6ympg0vh5yb5n669t.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.amazonaws.com%2Fuploads%2Farticles%2F2wf6ympg0vh5yb5n669t.png" alt="certificate-store" width="669" height="648"&gt;&lt;/a&gt;&lt;br&gt;
g. Click &lt;strong&gt;Finish&lt;/strong&gt;.The setup is complete once the import is successful.&lt;/p&gt;

&lt;h4&gt;
  
  
  Part 2: Login to the Database
&lt;/h4&gt;

&lt;p&gt;a. Gather the following details from the Aiven Overview Page:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Host Name&lt;/li&gt;
&lt;li&gt;Port&lt;/li&gt;
&lt;li&gt;Database Name&lt;/li&gt;
&lt;li&gt;Username&lt;/li&gt;
&lt;li&gt;Password&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;b. Open Power BI and click &lt;strong&gt;Get Data&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.amazonaws.com%2Fuploads%2Farticles%2F97usf49qgn0nrtos6kjb.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.amazonaws.com%2Fuploads%2Farticles%2F97usf49qgn0nrtos6kjb.png" alt="get-data" width="800" height="437"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;c. In the list, select &lt;strong&gt;More&lt;/strong&gt; and choose &lt;strong&gt;PostgreSQL Database&lt;/strong&gt;.&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fu5ouurqnxxdsekkckoqx.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.amazonaws.com%2Fuploads%2Farticles%2Fu5ouurqnxxdsekkckoqx.png" alt="postgres-database" width="800" height="513"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;d. Enter the &lt;strong&gt;Server Name&lt;/strong&gt; and &lt;strong&gt;Database Name&lt;/strong&gt; using the values copied from Aiven. Leave the data connectivity mode on the default &lt;strong&gt;Import&lt;/strong&gt; option.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Note:&lt;/strong&gt; The server name uses the format &lt;code&gt;hostname:port_number&lt;/code&gt;.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;e. Insert the server name as hostname and name of the database, then click &lt;strong&gt;OK&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.amazonaws.com%2Fuploads%2Farticles%2F8eqyc8sepukls8yhjjrh.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.amazonaws.com%2Fuploads%2Farticles%2F8eqyc8sepukls8yhjjrh.png" alt="server-name" width="754" height="424"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;f. Insert the username and password, then click &lt;strong&gt;Connect&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.amazonaws.com%2Fuploads%2Farticles%2Fyx8rrxdcf8wzlquwsc3u.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.amazonaws.com%2Fuploads%2Farticles%2Fyx8rrxdcf8wzlquwsc3u.png" alt="uname-password" width="800" height="429"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Loading Tables and Creating Relationships in Power BI
&lt;/h3&gt;

&lt;p&gt;A successful connection displays the tables stored in the database. In this case: &lt;strong&gt;Customers&lt;/strong&gt;, &lt;strong&gt;Products&lt;/strong&gt;, &lt;strong&gt;Sales&lt;/strong&gt;, and &lt;strong&gt;Inventory&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;a. Select the tables you require and load them into Power BI.&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.amazonaws.com%2Fuploads%2Farticles%2Fbaqztnjerul4deik73yv.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.amazonaws.com%2Fuploads%2Farticles%2Fbaqztnjerul4deik73yv.png" alt="data-tables" width="800" height="630"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;b. Open &lt;strong&gt;Power Query&lt;/strong&gt; and inspect the data. Clean inconsistent data, address any duplicates and null values, then save changes.&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.amazonaws.com%2Fuploads%2Farticles%2Fniqkulqi39us1uz4akge.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.amazonaws.com%2Fuploads%2Farticles%2Fniqkulqi39us1uz4akge.png" alt="power-query" width="800" height="358"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;c. Open the &lt;strong&gt;Model View&lt;/strong&gt; and create relationships between tables using common columns, typically primary and foreign keys. In some cases, Power BI selects relationships automatically. Review and delete any unwanted connections.&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.amazonaws.com%2Fuploads%2Farticles%2Fnm9ab05tbw2g2gmc8k5z.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.amazonaws.com%2Fuploads%2Farticles%2Fnm9ab05tbw2g2gmc8k5z.png" alt="data-models" width="800" height="457"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  What is Data Modeling?
&lt;/h4&gt;

&lt;p&gt;Data modeling is the process of defining how data is stored, structured, and related within a database or analytics tool like Power BI. Think of it as creating a &lt;strong&gt;blueprint&lt;/strong&gt; for your data so that different pieces of information can talk to each other.&lt;/p&gt;

&lt;h4&gt;
  
  
  Why Relationships Matter
&lt;/h4&gt;

&lt;p&gt;In a well-designed system, data is split into multiple tables: &lt;strong&gt;Customers&lt;/strong&gt;, &lt;strong&gt;Inventory&lt;/strong&gt;, &lt;strong&gt;Sales&lt;/strong&gt;, and &lt;strong&gt;Products&lt;/strong&gt; to avoid repetition and keep things organized. Relationships are the bridges that connect these tables using common fields, such as a Product ID. Without these connections, data exists in isolated containers. &lt;/p&gt;

&lt;p&gt;Relationships allow you to:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Combine Data&lt;/strong&gt;: See the name of a product next to its sales figures.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Analyze Correctly&lt;/strong&gt;:When you filter by category, sales numbers update to show only that category.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Support Accurate Reporting&lt;/strong&gt;: Prevent double-counting or mismatched information that leads to incorrect business decisions.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;In Power BI, the data model is what makes your dashboards interactive. When you click a slice of a pie chart, the rest of the report updates because of the underlying relationships.&lt;/p&gt;

&lt;h4&gt;
  
  
  Types of Relationships
&lt;/h4&gt;

&lt;p&gt;Once you've identified the connecting field, you must define the direction and cardinality of the relationship. The three most common types are:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Type&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;th&gt;Example&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;One-to-Many&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;The gold standard one record relates to many&lt;/td&gt;
&lt;td&gt;One product can be sold many times&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;One-to-One&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Used for splitting large tables&lt;/td&gt;
&lt;td&gt;Employees and Employee Sensitive Details&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Many-to-Many&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Complex multiple items on both sides relate&lt;/td&gt;
&lt;td&gt;Multiple products in multiple orders&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  Conclusion
&lt;/h3&gt;

&lt;p&gt;SQL (Structured Query Language) is often considered a handy tool for high-level Power BI work. While Power BI has great built-in tools for connecting to data, SQL allows you to handle the heavy lifting before the data even reaches your report.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;If Power BI is the kitchen where you cook the meal, SQL is the prep station where you wash, cut, and organize the ingredients.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;SQL does this by: &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Precise Retrieval:&lt;/strong&gt; Instead of importing a massive table with 100 columns you don't need, you can write a &lt;code&gt;SELECT&lt;/code&gt; statement to bring in only the specific columns required.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Efficient Filtering:&lt;/strong&gt; Using a &lt;code&gt;WHERE&lt;/code&gt; clause in SQL filters the data at the source (the database). This is much faster than importing millions of rows and filtering them inside Power BI.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Pre-Aggregated Data:&lt;/strong&gt; You can use &lt;code&gt;GROUP BY&lt;/code&gt; to sum up sales or average scores in the database. This creates a smaller dataset that makes your Power BI dashboards more responsive.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Data Transformation:&lt;/strong&gt; SQL is powerful for cleaning messy data, renaming columns, handling null values, or combining strings before the data model is even built.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>database</category>
      <category>datascience</category>
      <category>analyst</category>
      <category>postgres</category>
    </item>
    <item>
      <title>Master SQL: Navigating Joins and Windows Functions</title>
      <dc:creator>Erasto Wamuti</dc:creator>
      <pubDate>Mon, 02 Mar 2026 11:27:10 +0000</pubDate>
      <link>https://dev.to/erasto/master-sql-navigating-joins-and-windows-functions-2566</link>
      <guid>https://dev.to/erasto/master-sql-navigating-joins-and-windows-functions-2566</guid>
      <description>&lt;p&gt;When retrieving data from a database, there are specific conditions or criteria you may want to use to analyze that data. You might need to perform calculations, filter out relevant information, group data for specific analysis, or display aggregated results. SQL allows you to perform these operations on single or multiple tables by use of built-in functions. This article focuses on Joins and Window Functions.&lt;/p&gt;

&lt;h3&gt;
  
  
  JOINS
&lt;/h3&gt;

&lt;p&gt;Joins are used in querying related data that is stored in multiple tables. The tables, though different and containing specific parts of information, are related by having a common matching column that is used to relate them together.&lt;br&gt;
For instance, if you have data in a students table with the fields: name, student_id, residency, year, and a fee table with the fields: student_id, fee_paid, balance, you can relate the two using the student_id as a common field between the two.&lt;br&gt;
Different types of joins can be used in SQL, namely:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Inner Join:&lt;/strong&gt; This retrieves data from the database that matches from the two tables and ignores the records that don’t appear in both tables. Given our tables, a sample inner join script would be:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Select s.name, f.fee_paid 
from students s 
Inner join fee f 
On s.student_id = f.student_id 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The result of this query will be all the students who have paid the fee.&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.amazonaws.com%2Fuploads%2Farticles%2F0aj35rxbauz7nfjkpgp0.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.amazonaws.com%2Fuploads%2Farticles%2F0aj35rxbauz7nfjkpgp0.png" alt="inner-join-venn-diagram" width="800" height="436"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Left Join:&lt;/strong&gt; This retrieves all records that appear on the left table with matching records on the right; if a record appears on the left and not the right, the missing data is replaced with NULL values in the right table. It is important to note that the &lt;strong&gt;order&lt;/strong&gt; of the tables matters when writing the script. &lt;br&gt;
A sample script would be:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Select s.name, f.fee_paid 
from students s 
Left Join fee f 
On s.student_id = f.student_id
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This retrieves all student names and their corresponding fee payments made; if a student has not paid, the value on the rows from the fee table would be null.&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.amazonaws.com%2Fuploads%2Farticles%2Ftyf3719q02ilei4mjc4x.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.amazonaws.com%2Fuploads%2Farticles%2Ftyf3719q02ilei4mjc4x.png" alt="left-join-venn-diagram" width="800" height="436"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Right Join:&lt;/strong&gt; It works in a similar way as the Left Join, with the difference being the order of the tables. The results retrieved are from the right table with matching fields on the left and null values for non-matching rows on the left. Sometimes, the use of a right join can be negated by switching the order of the tables and using a Left Join instead.&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.amazonaws.com%2Fuploads%2Farticles%2Frcw5fsigyvzf3yx6zvu6.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.amazonaws.com%2Fuploads%2Farticles%2Frcw5fsigyvzf3yx6zvu6.png" alt="right-join-venndiagram" width="800" height="436"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Full Join:&lt;/strong&gt; This join retrieves all records from both tables and fills the unmatched data with nulls from both tables. It returns all records from the two tables and comes in handy when you are inspecting tables for NULL values. In our example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Select s.name, f.fee_paid 
from students s 
Full Join fee f 
On s.student_id = f.student_id
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Returns all records from students and the fee table, and NULL values for missing data from both 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.amazonaws.com%2Fuploads%2Farticles%2Fub605u940d6ddb7q140r.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.amazonaws.com%2Fuploads%2Farticles%2Fub605u940d6ddb7q140r.png" alt="full-join-venn-diagram" width="800" height="436"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Cross Join:&lt;/strong&gt; This type of join matches data from both tables in combinations. For instance, if you have table A with the fields: R, Y, G and another table with A, B, C, the result will be a combination of all the fields in the first table and the second. &lt;br&gt;
The results will be a combination of (total fields in 1st table) X (total fields in 2nd table).&lt;br&gt;
In our case:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Select * from table_1 
Cross join table_2
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;gives us these results: RA, RB, RC, YA, YB, YC, GA, GB, GC.&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.amazonaws.com%2Fuploads%2Farticles%2Fc3g0e7usqv3v9s314dp7.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.amazonaws.com%2Fuploads%2Farticles%2Fc3g0e7usqv3v9s314dp7.png" alt="cross-join-venn-diagram" width="800" height="436"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Window Functions
&lt;/h3&gt;

&lt;p&gt;These are functions that retrieve data that is aggregated over certain criteria without losing the individual row data. While Group By returns aggregated data in a compressed result depending on the grouping, Window functions maintain the row data and don’t compress the grouped data into a single row.&lt;br&gt;
An example would be:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Select year, sum(fee) 
from students 
Group by year 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This results in a table with collapsed rows and only one row to represent the group and the group total.&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.amazonaws.com%2Fuploads%2Farticles%2Fwnzkq8t4aq93t7l2wisw.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.amazonaws.com%2Fuploads%2Farticles%2Fwnzkq8t4aq93t7l2wisw.png" alt="table-with-aggregation-group-by" width="389" height="236"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A window function would look like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Select year, fee, sum(fee) over(partition by year) 
from students
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The window function does not collapse the grouped data; it aggregates the sum and returns it in each row.&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.amazonaws.com%2Fuploads%2Farticles%2F9pm6ur6o464zbmub8stt.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.amazonaws.com%2Fuploads%2Farticles%2F9pm6ur6o464zbmub8stt.png" alt="table-with-window-function-aggregation" width="557" height="391"&gt;&lt;/a&gt;&lt;br&gt;
The syntax of a window function, therefore, is:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[function] OVER (expression1, expression2, expression3, …)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The &lt;strong&gt;&lt;em&gt;OVER&lt;/em&gt;&lt;/strong&gt; keyword identifies the window over which you want to apply the function. A window is a subset of your data.&lt;/p&gt;

&lt;h4&gt;
  
  
  Functions
&lt;/h4&gt;

&lt;p&gt;This is the first part of a window function. Here, any aggregate function (sum, count, avg, min, max), rank functions (row_number, rank, dense_rank, cume_dist, percent_rank, ntile), and analytic functions (lead, lag, first_value, last_value) can be used.&lt;br&gt;
The second part checks the condition or criteria you want to apply to the view. &lt;br&gt;
Some of the expressions that can be used are:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Partition By&lt;/strong&gt;: This keyword specifies the dimension or gives the criteria for dividing the data. Example: [function] Over (Partition by year, payment_status ), groups the subset of data into common years and payment status.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Order By&lt;/strong&gt;: This sorts each subset of data (window) into ascending or descending order. Example: [function] Over (Order by year asc ).&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It’s important to note that more expressions or multiple conditions can be used after the &lt;strong&gt;&lt;em&gt;OVER&lt;/em&gt;&lt;/strong&gt; clause to further organize the data in the individual windows.&lt;/p&gt;

</description>
      <category>beginners</category>
      <category>database</category>
      <category>sql</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>How Analysts Translate Messy Data, DAX, and Dashboards into Action Using Power BI</title>
      <dc:creator>Erasto Wamuti</dc:creator>
      <pubDate>Thu, 19 Feb 2026 06:17:44 +0000</pubDate>
      <link>https://dev.to/erasto/how-analysts-translate-messy-data-dax-and-dashboards-into-action-using-power-bi-46mf</link>
      <guid>https://dev.to/erasto/how-analysts-translate-messy-data-dax-and-dashboards-into-action-using-power-bi-46mf</guid>
      <description>&lt;p&gt;Modernization of business transactions and record keeping has seen more collection and use of data. This has in turn grown the need to use that data to understand past trends and use that knowledge to improve or make decisions. This has seen the increased demand of Business Analysts or Data Analysts. &lt;br&gt;
So how exactly does an analyst go about data to get to the decision part?&lt;/p&gt;

&lt;h3&gt;
  
  
  Data Sources
&lt;/h3&gt;

&lt;p&gt;When data is collected from the field, it may not be organized or clean. The first thing an analyst does is to understand the data presented to them and what it means. Say if a school collects data, or a hospital collects patient data or a farmer collects data etc. The data in these scenarios is specific to a certain field. &lt;/p&gt;

&lt;h3&gt;
  
  
  Data Tools
&lt;/h3&gt;

&lt;p&gt;There are many tools that can be used to organize, clean and generate reports. Power BI is an example that is mostly used for this purpose. There are more business intelligence tools such as Apache Superset, Tableau etc that can also be used.&lt;/p&gt;

&lt;h3&gt;
  
  
  Analysis Steps
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;1. Cleaning Data&lt;/strong&gt;&lt;br&gt;
The first thing an analyst does it to clean and organize the data depending on the nature of the data sourced. Data cleaning involves removing duplicate values, filling missing information with relevant data, establish and assigning data types. &lt;br&gt;
Power BI gives an analyst the option to pick data from various sources e.g spreadsheet, database, online services etc. The data is then loaded onto the platform. Cleaning of data is performed when it’s transformed into power query for application of the above steps.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. Organizing Data&lt;/strong&gt;&lt;br&gt;
Most data is organized in tables or schemas. Power BI has a modelling page that is used to organize the data and create relationships to related fields. The data about students may be in form of registration information table, fee payment table, hostel information table, examination payment information table etc. &lt;br&gt;
For analysis to be done the tables need to be related with common fields (primary and foreign keys) so that one can bring all the data about a student from different tables to analyse it. This organization and crating relationships between table is what is referred to as data modelling.&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.amazonaws.com%2Fuploads%2Farticles%2Fkxuocabmxkv94p0z0gkg.webp" 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.amazonaws.com%2Fuploads%2Farticles%2Fkxuocabmxkv94p0z0gkg.webp" alt="Data Modelling in Power BI" width="800" height="523"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. Analysing Data&lt;/strong&gt;&lt;br&gt;
Next, an analyst performs calculations on respective data which includes totals, averages, sorting data etc. This is done to derive key metrics such as total fees paid by students, total registrations, average age of the students enrolled in certain courses etc. &lt;br&gt;
In Power BI these calculations are carried out by a series of Data Analysis Expressions (DAX language). These functions and expressions gives an analyst the platform to manipulate the data and get key metrics.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;4. Data Presentation&lt;/strong&gt;&lt;br&gt;
After data is analysed, the analyst needs to visualize it for presentation to decision makers. This is done by creating different charts and combining data points that can be drawn insights from.&lt;br&gt;
Power BI has different charts that can represent the related data and data points. There are cards that represent key metrics. Column charts for related data such as Relationship between student age and hostel booking rates, fee payment as related to the examination date etc.&lt;/p&gt;

&lt;p&gt;When one plots the various charts, the key performance indicators are combined   into one visual dashboard. A dashboard is a combination of the key metrics on one page that a decision maker can have a look and see trends, relationships and performance analysis. After which they can make decisions based on that.&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.amazonaws.com%2Fuploads%2Farticles%2F2cn24tcawcbespnfih1o.webp" 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.amazonaws.com%2Fuploads%2Farticles%2F2cn24tcawcbespnfih1o.webp" alt="Dashboard" width="640" height="357"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;From raw data collected, an analyst walks through data cleaning, transforming, data modelling, data manipulation using DAX, and data visualization for drawing insights.&lt;/p&gt;

</description>
      <category>data</category>
      <category>datascience</category>
      <category>dataengineering</category>
      <category>machinelearning</category>
    </item>
    <item>
      <title>Data Modelling and Schemas in Power BI</title>
      <dc:creator>Erasto Wamuti</dc:creator>
      <pubDate>Mon, 16 Feb 2026 03:59:55 +0000</pubDate>
      <link>https://dev.to/erasto/data-modelling-and-schemas-in-power-bi-4aak</link>
      <guid>https://dev.to/erasto/data-modelling-and-schemas-in-power-bi-4aak</guid>
      <description>&lt;p&gt;Data modelling is the process of connecting data structures, creating relationships between them and organizing the data for analysis. In Power BI data models are created when the data sources are loaded on the platform in the form of tables.&lt;/p&gt;

&lt;h4&gt;
  
  
  Table Types
&lt;/h4&gt;

&lt;p&gt;We may categorize tables containing data in quantitative and descriptive terms. The tables with data that can be aggregated are referred to as Fact tables. Dimension tables are those which describe the data in terms of where, when, and why attributes of the data.&lt;br&gt;
For instance a fact table may include the sales, quantity, amount etc while a dimension table may include the location, city and date attributes.&lt;/p&gt;

&lt;h4&gt;
  
  
  Schema
&lt;/h4&gt;

&lt;p&gt;The logical representation of the relationships between tables is what is referred to as a schema. Data is correlated using relationships between fact tables and dimension tables on the model view of Power BI.&lt;br&gt;
A relationship is created between tables when the primary and foreign keys are connected together in a schema.&lt;br&gt;
Sample Schema:&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.amazonaws.com%2Fuploads%2Farticles%2Ffaxjs2h5zz5rxsh3k8ur.webp" 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.amazonaws.com%2Fuploads%2Farticles%2Ffaxjs2h5zz5rxsh3k8ur.webp" alt="Data Schema" width="800" height="444"&gt;&lt;/a&gt;&lt;br&gt;
Schemas can be structured in two ways:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Star Schema&lt;/strong&gt;.This is the arrangement that connects dimension tables with fact tables using a direct relationship. Example:&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fo19d09qv21yagok7y48t.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.amazonaws.com%2Fuploads%2Farticles%2Fo19d09qv21yagok7y48t.png" alt="Star Schema" width="800" height="501"&gt;&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Snowflake Schema&lt;/strong&gt;.This arrangement connects fact tables with dimension tables with dimension tables having other sub-dimension relationships. Example:&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fe23mnkljrczmai4ny2ot.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.amazonaws.com%2Fuploads%2Farticles%2Fe23mnkljrczmai4ny2ot.png" alt="Snowflake" width="800" height="483"&gt;&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The difference between the two structures is that dimension tables in star schemas have a direct relationship with the fact tables while all dimension tables in snowflake structures don’t have a direct relationship.&lt;br&gt;
This affects query performance in that, star schemas have only one hop through the relationships while snowflake have 2 or more hops when querying the data.&lt;/p&gt;

</description>
      <category>datascience</category>
      <category>dataengineering</category>
      <category>analytics</category>
      <category>machinelearning</category>
    </item>
    <item>
      <title>Introduction to MS Excel for Data Analytics</title>
      <dc:creator>Erasto Wamuti</dc:creator>
      <pubDate>Mon, 26 Jan 2026 11:33:49 +0000</pubDate>
      <link>https://dev.to/erasto/introduction-to-ms-excel-for-data-analytics-5dli</link>
      <guid>https://dev.to/erasto/introduction-to-ms-excel-for-data-analytics-5dli</guid>
      <description>&lt;p&gt;In times past business records have been known to be stored in ledgers. These are books with detailed transaction history, sales and inventory. In modern times the evolving technology has improved the practice from ledgers  to spreadsheets. So what is a spreadsheet?&lt;br&gt;
A spreadsheet is a software that captures data, stores data and can be used to analyse that data depending on a user’s requirements. There are different applications that can be used as spreadsheet namely: Microsoft Excel, Google Sheets, Apple Numbers, LibreOffice Calc etc&lt;br&gt;
This tutorial will focus on Microsoft Excel.&lt;br&gt;
Excel is a program that is made by Microsoft and is widely used to store, analyse and present data. Data is organized into rows and columns and can be in various formats. &lt;br&gt;
Here are fundamental concepts to note as you deal with Excel:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Excel Interface:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Menubar:This is the section that gives you options on what you want to do within the spreadsheet. That includes formatting the details, headers, values and the general look of the sheet.&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.amazonaws.com%2Fuploads%2Farticles%2Fmxvvimgzxf9ww06raaja.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.amazonaws.com%2Fuploads%2Farticles%2Fmxvvimgzxf9ww06raaja.png" alt="excel menubar" width="800" height="181"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Formula Bar: Displays the current cell you are currently on, and can be used to insert or edit a formula.
Formula Bar: Displays the current cell you are currently on, and can be used to insert or edit a formula.&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.amazonaws.com%2Fuploads%2Farticles%2Fnszmzowspxbtuhhetx1q.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.amazonaws.com%2Fuploads%2Farticles%2Fnszmzowspxbtuhhetx1q.png" alt="excel formulabar" width="800" height="188"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Column, Row and Address:
Excel arranges data in the form of rows(run horizontally), columns(run vertically) and cells (intersection of a row and column) as shown below.
The cells are assigned addresses to make it easy to reference the data as shown above. For instance the current active cell is G10.&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.amazonaws.com%2Fuploads%2Farticles%2Fppw2eyy0q5ju6mo2p2k3.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.amazonaws.com%2Fuploads%2Farticles%2Fppw2eyy0q5ju6mo2p2k3.png" alt="Worksheet referencing" width="800" height="413"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Workbook and Worksheets: 
When one opens a new excel file, the spreadsheet opened is a new workbook which can contain more than one worksheet as shown below. This makes data management efficient for related data.&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.amazonaws.com%2Fuploads%2Farticles%2Fcoug5h922gve5x2j2tuf.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.amazonaws.com%2Fuploads%2Farticles%2Fcoug5h922gve5x2j2tuf.png" alt="excel worksheets" width="800" height="244"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Data Types
&lt;/h3&gt;

&lt;p&gt;Excel handles data of different data types such as Text(String), Numbers(integers and floats), Date/Time, Currency etc. This helps to validate data and work format data to the required format.&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.amazonaws.com%2Fuploads%2Farticles%2Fo6z6f7lti7dvzgbl1fsj.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.amazonaws.com%2Fuploads%2Farticles%2Fo6z6f7lti7dvzgbl1fsj.png" alt="Excel Data Types" width="800" height="465"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Formula &amp;amp; Functions
&lt;/h3&gt;

&lt;p&gt;Formula are user defined mathematical operations that a user performs on a cell or range of cells. Functions are inbuilt(come with excel software) mathematical and statistical formulae that help in calculations, and analysing the data. A few Examples include;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Formula: Multiplication, Division, Subtraction, Addition etc&lt;/li&gt;
&lt;li&gt;Functions: SUM(), AVERAGE(), COUNT(), MOD(), MIN() etc.&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.amazonaws.com%2Fuploads%2Farticles%2F61lbeuuifdmu9ptd0q6z.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.amazonaws.com%2Fuploads%2Farticles%2F61lbeuuifdmu9ptd0q6z.png" alt="Execl-Functions" width="800" height="420"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  4. Data Analysis
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Filtering and Sorting&lt;/strong&gt;:
Excel enables you to work on a subset of data depending on a defined condition. This is what a filter does. For example, you can filter class data depending on the age of students.
Sorting means you can arrange data in a certain order either ascending and descending. This can help in glancing at the upper and lower data limits.&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.amazonaws.com%2Fuploads%2Farticles%2F701g9ejiyerxgax5zwvw.jpg" 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.amazonaws.com%2Fuploads%2Farticles%2F701g9ejiyerxgax5zwvw.jpg" alt="filtering" width="450" height="445"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Conditional Formatting&lt;/strong&gt;: You may want to highlight data that fits a certain criteria. E.g Highlight in red all the dates that fall on national holidays in a year.&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.amazonaws.com%2Fuploads%2Farticles%2Fesyeqjpeha55krjmklm0.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.amazonaws.com%2Fuploads%2Farticles%2Fesyeqjpeha55krjmklm0.png" alt="Conditionalformating" width="800" height="339"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Tables&lt;/strong&gt;: excel enables you to convert data within a specified range to a table. This makes filtering and sorting operations easier and structured.Example of a table:&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.amazonaws.com%2Fuploads%2Farticles%2F3dx42jqvkub6i4fnh2sc.webp" 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.amazonaws.com%2Fuploads%2Farticles%2F3dx42jqvkub6i4fnh2sc.webp" alt="Excel Table" width="800" height="449"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Charts&lt;/strong&gt;: Charts are used to visualize data which is used for data presentation. This makes it easier to see trends within the data. There are different charts that are suitable for different scenarios, e.g bar charts, line charts, circle charts, etc&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fzhrm48dr4f52o88038bh.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.amazonaws.com%2Fuploads%2Farticles%2Fzhrm48dr4f52o88038bh.png" alt="Charts" width="794" height="756"&gt;&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Dashboard&lt;/strong&gt;: This is a view that represents key KPI metrics. With a quick view you can analyze and see the data trends and talking points from the view. The view gives a summary and insights can be drawn from the view from the metrics shown. An example is shown below; &lt;/p&gt;&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.amazonaws.com%2Fuploads%2Farticles%2Fcahcylkhsu5ts1l0teuy.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.amazonaws.com%2Fuploads%2Farticles%2Fcahcylkhsu5ts1l0teuy.png" alt="Excel Dashboard" width="800" height="599"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;There are more excel features and functions that enhance data analysis and statistical analysis further. You can explore more on this link .&lt;br&gt;
&lt;a href="https://support.microsoft.com/en-us/excel" rel="noopener noreferrer"&gt;More on MS Excel&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>analyst</category>
      <category>datascience</category>
      <category>dataengineering</category>
      <category>beginners</category>
    </item>
    <item>
      <title>Git and Github for Beginners</title>
      <dc:creator>Erasto Wamuti</dc:creator>
      <pubDate>Sat, 17 Jan 2026 19:09:56 +0000</pubDate>
      <link>https://dev.to/erasto/git-and-github-for-beginners-3aik</link>
      <guid>https://dev.to/erasto/git-and-github-for-beginners-3aik</guid>
      <description>&lt;p&gt;&lt;strong&gt;Picture this&lt;/strong&gt;: you are a member of a team that is working on a research paper. Each team member is given their own section to contribute to the final presentation document. This is a team project, and everyone will work on their sections at their own time, then all changes will be combined for the final paper. Does this sound familiar? &lt;br&gt;
This is what software and data engineering engineers do: teamwork, version control, and collaboration on projects. But instead of using word editors, they make use of git and GitHub for project tracking and collaboration. So what is git and github?&lt;br&gt;
&lt;strong&gt;Git&lt;/strong&gt; is a version control tool that tracks project files, stores the histories of all the changes that a project undergoes, and keeps a log of all actions taken by all people connected to that project. This is important in big projects that teams work on for version control and future improvements.&lt;br&gt;
&lt;strong&gt;Github&lt;/strong&gt; on the other hand, is an online platform that enables members of a team to collect all their individual work together in one project directory and create the combined full project. &lt;/p&gt;
&lt;h4&gt;
  
  
  Git Installation Process
&lt;/h4&gt;

&lt;ol&gt;
&lt;li&gt;Go to the &lt;a href="https://git-scm.com/install/windows" rel="noopener noreferrer"&gt;Git official page&lt;/a&gt; and download the version that matches your computer operating system. (This use case is for Windows users).&lt;/li&gt;
&lt;li&gt;Open the setup file that was downloaded on your computer and start the installation process. &lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Select Components&lt;/strong&gt;: Leave the default options as selected and click on Next.
&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.amazonaws.com%2Fuploads%2Farticles%2F4ed4ysccbn3a6l6a7ptw.png" alt="Select Git Components" width="786" height="605"&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Choosing the default editor used by Git&lt;/strong&gt;: Select the editor you have installed on your computer from the dropdown list(Notepad, Visual Studio Code, Sublime Text, etc.). If unsure, select Notepad since it is a default  Windows editor.
&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.amazonaws.com%2Fuploads%2Farticles%2F8m7ne4gont7y5hhnshrc.png" alt="git Editor" width="787" height="609"&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Adjusting the name of the initial branch in new repositories&lt;/strong&gt;: Select the second option. (change to main)
&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.amazonaws.com%2Fuploads%2Farticles%2F3962lxu54re5jxbmuaf7.png" alt="Override Main" width="793" height="606"&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Adjusting your Path environment&lt;/strong&gt;: Select the default option selected
&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.amazonaws.com%2Fuploads%2Farticles%2Ft9zhs38kml26f7f31uuq.png" alt="Path Environment" width="789" height="607"&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Choosing the SSH executable&lt;/strong&gt;: Select the default option selected
&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.amazonaws.com%2Fuploads%2Farticles%2Fqxbhseb56lgpvohtw4xn.png" alt="SSH Libarary" width="787" height="611"&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Choosing HTTPS transport backend&lt;/strong&gt;: Select the Native Windows Secure Channel Library.
&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.amazonaws.com%2Fuploads%2Farticles%2Fvm03am2izv0y4rkbdgoz.png" alt="HTTPS Channel" width="794" height="611"&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Configuring the line ending conversions&lt;/strong&gt;: Leave the default option as selected(Windows Style)
&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.amazonaws.com%2Fuploads%2Farticles%2F8kbqqlknyuahaj4t56qr.png" alt="Line ending" width="792" height="610"&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Configuring the terminal emulator to use Git Bash&lt;/strong&gt;: Leave the default option as selected.(Use Mintty)
&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.amazonaws.com%2Fuploads%2Farticles%2Fs0nn9ib43g85z42e69k9.png" alt="Terminal emulator" width="784" height="609"&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Choosing the default behavior of ‘git pull’&lt;/strong&gt;: Leave the default option as selected(Fast-Forward or Merge)
&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.amazonaws.com%2Fuploads%2Farticles%2Fy0ed8y4r0ta869fk7win.png" alt="Default git pull" width="788" height="608"&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Choose a credential helper&lt;/strong&gt;: Select none
&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.amazonaws.com%2Fuploads%2Farticles%2Fplqlievjpgbtmorj0a5w.png" alt="Git Credential helper" width="794" height="608"&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Configuring Extra Options&lt;/strong&gt;: Select enable file system caching.
&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.amazonaws.com%2Fuploads%2Farticles%2Fc992oqygcdu19m5skw3d.png" alt="Extra Git options" width="786" height="605"&gt;
&lt;/li&gt;
&lt;li&gt; Start the &lt;strong&gt;installation&lt;/strong&gt; process.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Once finished, select launch Git Bash. This will open up a terminal window that resembles the Windows cmd.&lt;/p&gt;
&lt;h4&gt;
  
  
  Configuring Git and GitHub
&lt;/h4&gt;

&lt;p&gt;Git will need to be configured so that the main user and email are saved. This is required so that Git can always record this user attached to every update posted on the project file that it tracks.&lt;br&gt;
&lt;strong&gt;Configuration:&lt;/strong&gt;&lt;br&gt;
I. Launch Git Bash and set up your name and email by typing the following commands:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git config --global user.name "Your Name"
git config --global user.email "your.email@example.com"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Replace the fields in quotes with your name and email.&lt;br&gt;
Ii. Verify the Git installation by typing the following command on Git Bash:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git –version
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;A response with a version number will appear for a completed installation. If an error appears, repeat the installation process from the setup downloaded from git main page.&lt;/p&gt;

&lt;h4&gt;
  
  
  Signing up for GitHub:
&lt;/h4&gt;

&lt;p&gt;Get to &lt;a href="https://github.com/" rel="noopener noreferrer"&gt;Github&lt;/a&gt; and sign up for an account if you don’t have an existing one(Login if you already have an existing account). Fill out the details(email,password, username, country) and save.&lt;/p&gt;

&lt;h4&gt;
  
  
  Connecting Git to GitHub
&lt;/h4&gt;

&lt;p&gt;As discussed earlier, GitHub is an online collaboration tool that helps teams to work on projects and store every user's contributions and history on the platform. There are more collaboration tools like GitLab and Bitbucket, but this tutorial focuses on GitHub.&lt;br&gt;
You can connect to GitHub using GitBash/terminal/command line interface through &lt;strong&gt;HTTPS&lt;/strong&gt;(HyperText Transfer Protocol Secure) or &lt;strong&gt;SSH&lt;/strong&gt;(Secure Shell).&lt;br&gt;
HTTPS method requires password authentication using access tokens every time you pass a push or pull command to a GitHub repository. You have to use a credential helper to avoid doing this for every session(extra step).&lt;br&gt;
SSH, on the other hand, uses a key pair of public and private keys, and the setup is done once. A stored passphrase is used for subsequent times, hence prompting for authentication occurs only once. This makes it convenient for the many times a user performs pushes or pulls from the remote GitHub platform to their local pc.&lt;/p&gt;
&lt;h4&gt;
  
  
  Establishing Connection through SSH:
&lt;/h4&gt;

&lt;p&gt;&lt;strong&gt;Step 1&lt;/strong&gt;: Generate a pair of SSH keys using the following command on Git bash terminal.&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;`ssh-keygen -t rsa -b 4096 -C “your email”`

Press Enter on the terminal when prompted for file location.
Press Enter on the terminal when prompted for the passphrase(saves the key in the default location with the default passphrase)
A pair of public and private keys is successfully generated.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;p&gt;&lt;strong&gt;Step 2&lt;/strong&gt;: Copy the public key from the default location by typing this command on the git bash terminal.&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;`clip &amp;lt; ~/.ssh/id_rsa.pub`
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;p&gt;&lt;strong&gt;Step 3&lt;/strong&gt;: Sign in to your GitHub account online and navigate to account settings.&lt;br&gt;
&lt;strong&gt;Step 4&lt;/strong&gt;: Select the ‘SSH and GPG keys’ option on the left menu.&lt;br&gt;
&lt;strong&gt;Step 5&lt;/strong&gt;: Select the “Add new SSH Key” option and paste the copied public key in the field provided, and name the key.&lt;/p&gt;
&lt;h4&gt;
  
  
  Start using Git
&lt;/h4&gt;

&lt;p&gt;With these steps, Git is successfully installed and connected to GitHub. You can use git for collaboration and version control.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Sign in to your GitHub account and create a new repository.&lt;/li&gt;
&lt;li&gt;Select SSH and copy the link to the repository. &lt;/li&gt;
&lt;li&gt;On your local computer, in the Git Bash terminal, navigate to the folder you want to save your project work and create a folder. (Use the cd command, e.g., “cd Documents/Projects/NewGitProject”)&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Run the following command to download the repository from GitHub and establish its connection to GitHub.&lt;/p&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;`git clone &amp;lt;your copied repository link&amp;gt;`
&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The local folder is now up to date with the remote repository.&lt;/p&gt;

&lt;p&gt;If you have a folder on your local pc and wish to create a new repository and upload it to GitHub, you can follow these steps.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Use the cd command to navigate on git bash terminal to the folder, then run:&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;git init&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;Stage all your files in the folder to commit by running:&lt;/p&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt; `git add .`
&lt;/code&gt;&lt;/pre&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;Commit the changes and use the m flag to add a message that describes the update.&lt;/p&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt; `git commit -m "my commit message"`
&lt;/code&gt;&lt;/pre&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;Connect the local repository/directory to your remote repository on GitHub by running the command.&lt;/p&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt; `git remote add origin &amp;lt;replace using repository url from GitHub created&amp;gt;`
&lt;/code&gt;&lt;/pre&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;Push your local commits to the remote GitHub platform using;&lt;/p&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  `git push -u origin main`
&lt;/code&gt;&lt;/pre&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;Every time a change is updated on GitHub by another team member, you can always perform “git pull” command on the directory on git bash terminal to download the latest version to your local pc.&lt;/p&gt;

&lt;p&gt;These steps have helped you use basic git commands to push local updates and pull updates in the remote repository to your local pc. &lt;br&gt;
There are more collaboration and version control features in git that this tutorial has not mentioned. You can explore more on this link: &lt;a href="https://www.geeksforgeeks.org/git/git-features/" rel="noopener noreferrer"&gt;Git Features&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>data</category>
      <category>datascience</category>
      <category>beginners</category>
      <category>machinelearning</category>
    </item>
  </channel>
</rss>
