{"id":4653,"date":"2020-05-23T17:08:56","date_gmt":"2020-05-23T09:08:56","guid":{"rendered":"https:\/\/tommykwan.com\/blog\/?p=4653"},"modified":"2020-05-23T19:30:08","modified_gmt":"2020-05-23T11:30:08","slug":"importing-data-into-power-bi-desktop","status":"publish","type":"post","link":"https:\/\/tommykwan.com\/blog\/it\/power-bi\/importing-data-into-power-bi-desktop\/","title":{"rendered":"Importing Data into Power BI Desktop"},"content":{"rendered":"[Ref Beginning Microsoft Power BI ISBN 978-1-4842-5619-0]\n<p>The<strong> first step<\/strong> in creating the Power BI model is<strong> importing data<\/strong>. We can import data from a variety of data sources:<\/p>\n<ol>\n<li class=\"epub__Heading\">Relational Databases<\/li>\n<li>Online sources\n<ol>\n<li>Web services [online analytical processing (OLAP) database]<\/li>\n<li><span id=\"ITerm45\">SQL Server Analysis Service (SSAS)<\/span><\/li>\n<\/ol>\n<\/li>\n<li>Text Files<\/li>\n<\/ol>\n<p>(Here are only few examples, there are far more sources in the software)<\/p>\n<p>&nbsp;<\/p>\n<p>The<strong> second step<\/strong> in creating the Power BI model is<strong> <a href=\"https:\/\/tommykwan.com\/blog\/it\/whats-data-munging\/\" target=\"_blank\" rel=\"noopener noreferrer\">&#8220;data munging&#8221;<\/a><\/strong>. You create a connection, preview the data, and then import it into the model. Data from these sources often needs to be scrubbed and transformed (perform <a href=\"https:\/\/tommykwan.com\/blog\/it\/whats-data-munging\/\" target=\"_blank\" rel=\"noopener noreferrer\">&#8220;data munging&#8221;<\/a>) before it can be useful and imported into a model. Power <span id=\"ITerm61\">Query is<\/span> a powerful tool performing <a href=\"https:\/\/tommykwan.com\/blog\/it\/whats-data-munging\/\" target=\"_blank\" rel=\"noopener noreferrer\">&#8220;data munging&#8221;<\/a> in Power BI.<\/p>\n<p>The basic data munging skills include:<\/p>\n<ol>\n<li>Cleanse data\n<ol>\n<li>removing duplicates<\/li>\n<li>replacing values<\/li>\n<li>removing error values<\/li>\n<li>changing data types<\/li>\n<\/ol>\n<\/li>\n<li>filtering data (remove unnecessary columns and rows)<\/li>\n<li>Merge (Columns)\n<ul>\n<li>For the lookup table, you can uncheck the Enable\u00a0<span id=\"ITerm30\">Load<\/span>\u00a0by right-clicking the query in the Queries list window<\/li>\n<li>click the Merge Queries drop-down<\/li>\n<li>Choosing columns to\u00a0<span id=\"ITerm38\">keep (show)<\/span><\/li>\n<\/ul>\n<\/li>\n<li>Appending Data (combine table)<\/li>\n<li>Splitting Data (by comma &#8220;,&#8221; for example)<\/li>\n<li>Unpivoting Data<\/li>\n<li>Group and aggregate data<\/li>\n<li>Insert calculated columns<\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>[Ref Beginning Microsoft Power BI ISBN 978-1-4842-5619-0] The first step in creating the Power BI model is importing data. We can import data from a variety of data sources: Relational Databases Online sources Web services [online analytical processing (OLAP) database] SQL Server Analysis Service (SSAS) Text Files (Here are only few examples, there are far<a class=\"read-more \" href=\"https:\/\/tommykwan.com\/blog\/it\/power-bi\/importing-data-into-power-bi-desktop\/\" title=\"Read More\"> <span class=\"button default\">Read More<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[27,26],"tags":[],"class_list":["post-4653","post","type-post","status-publish","format-standard","hentry","category-it","category-power-bi"],"_links":{"self":[{"href":"https:\/\/tommykwan.com\/blog\/wp-json\/wp\/v2\/posts\/4653","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/tommykwan.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/tommykwan.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/tommykwan.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/tommykwan.com\/blog\/wp-json\/wp\/v2\/comments?post=4653"}],"version-history":[{"count":12,"href":"https:\/\/tommykwan.com\/blog\/wp-json\/wp\/v2\/posts\/4653\/revisions"}],"predecessor-version":[{"id":4670,"href":"https:\/\/tommykwan.com\/blog\/wp-json\/wp\/v2\/posts\/4653\/revisions\/4670"}],"wp:attachment":[{"href":"https:\/\/tommykwan.com\/blog\/wp-json\/wp\/v2\/media?parent=4653"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/tommykwan.com\/blog\/wp-json\/wp\/v2\/categories?post=4653"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/tommykwan.com\/blog\/wp-json\/wp\/v2\/tags?post=4653"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}