Power BI Knows Dates

Back in PowerPivot days, if I wanted to be able to drill down through a report by dates (Year, Quarter, Month, Day), I had to build the hierarchy and typically I had to build custom columns to hold these date parts. I would even have to do some fancy ‘Sort by Column’ changes to get the months of the year to display in the correct order. Power BI takes a lot of that work away and makes it easy to drill down through your data.

Let me start by loading some data from the Adventure Works Data Warehouse database. In the figure below, you can see that I’ve loaded several of the tables from this database, but for today I’m going to focus on just two tables, FactInternetSales and DimDate. The first thing I notice is that these two tables are connected with three relations represented by three lines, one solid and two dotted. This is because DimDate is a role playing dimension since there are multiple dates in the FactInternetSales table that could be associated with the date table to create reports.

By clicking on any of the relationships, I can see which fields are associated with that relationship since the field names will be enclosed in a box. In the figure below, you can see that the active relationship (the solid line) connects the DateKey field in DimDate with the DueDateKey in the FactInternetSales table.

However, I want to use one of the other relationships. To change which relationship is active, I can open the Data Tools Modeling toolbar and select the Manage Relationships button.

You can see that 6 active relationships have been set between the tables and two are currently inactive.

Suppose I want to use the OrderDateKey for my report. It would be nice if I could just click on the relationship that I want and like radio buttons (or option buttons) the previous relationship would be marked inactive and the new relationship would become active. Unfortunately, this just results in an error screen as shown here.

You have to first mark the relationship that you do not want as inactive by clicking on the yellow checkbox to the left of the relationship. Then you can select the relationship you want as shown in the next figure.

Now when I return to my Relationships page, the active connection is now linking the DateKey field in DimDate with the OrderDateKey field in the FactInternetSales table

I did this just to show that I can still work with the tables like I did in PowerPivot, but I really did not need to do any of this. If I open the Reports page and in the right side fields panel select first Sales Amount and then Order Date which is defined as the data type Date/Time, I will get a table that looks something like the following:

If I then switch to a stacked column chart, I will see a chart like the following (after a few formatting changes) that displays the Sales Amount by Year.

If I click on any of the columns, a dialog box appears with some details about that column. However, that is not what I want. I want to be able to drill down on any given year when I click on it.

In a relatively recent enhancement to PowerBI Desktop, several buttons have been added to the header. If I click on the icon third from the right as shown in the next figure, I can toggle the Drill Down feature. Drill down is turned on when the icon is mostly black instead of white.

Now when I click on the third column from the left (the 3rd quarter) the chart automatically updates to display sales by month and it displays the months July, August, and September in the correct order as shown next.

Clicking on the August column of this chart drills down to the next date level which is days in the month as shown here.

At any time, I can move back up the hierarchy by clicking the icon on the far left side of the header which is the Drill Up icon.

In fact, if I click on this icon twice, I can return to the Sales by Quarter chart. Now suppose I want a chart that displays all the months in the year. The button second from the left lets me drill down for all the current column on the current chart to the next level. So if I am displaying quarters, it show me the sales by month.

As you can see in the following chart, all the months in the year now appear. But perhaps more surprising is that the months appear in the correct chronological order, something we would have had to do with a Sort by Column option in a standard PowerPivot chart.

I hope you found that ability to drill down through a date hierarchy automatically without having to build that hierarchy first as interesting as I did. I’m at a SQL Saturday today in Tampa presenting an introduction to Power BI to the attendees. Maybe I’ll see you there.

C’ya next time.

Spring Cleaning Time for SharePoint Sites

We have been deeply involved in a cleanup of our SharePoint portal plan for the last several weeks and I thought I would share with you some of our observations because I know most of you with both Internet and intranet sites that are more than a few years old probably share the same issues we do. Our Internet and intranet portals have been around for 9 and 8 years respectively and over time, a lot of ‘junk’ has accumulated. The example I like to use is that it is similar to the way your email slowly fills up with ‘junk’ over time. For example, if you received 20 emails a day, but only have time to address 19 of them, you may go home feeling pretty good about the amount of work you got done. However, that 1 email you did not get to if you consider have only 1 email that you do not get to each day over the course of a typical work year can amount to over 250 emails. Of course, if you get more than 20 emails and the number that you do not get to is greater than 1, that total can expand much more rapidly.

So how do you get a handle on the problem? You could simply delete anything older than 2 weeks old, but that might delete important email messages that you really need to see. On the other hand, the email that you received yesterday and did not get to may be a total waste of time. Clearly the age of the email is not the only deciding factor. Maybe you choose to delete all emails from people outside of your department. Unfortunately, some of those emails from other departments may be more important than the email that circulated around asking people where they wanted to go to lunch on Friday. You could delete anything that comes from outside of the company. That would certainly help keep you focused on your work, but you would also miss notifications of appropriate training or white papers relevant to your job.

Thus you can see that cleaning out your inbox can be more complex than any simple rule or a set of rules (although they may help). It is also important to perform that cleanup on a more frequent basis than once every year. One a month may not be too often and even once a week perhaps on Friday afternoon as you are winding down for the week might be a good choice.

In a similar way, if you have both an Internet and intranet portal (hey, even if you only have a collaboration site), periodic cleanup is still something you need to consider doing. If nothing else, cleaning out old obsolete content will make search run faster and return more relevant results. So here are a few tips that may help you perform your own portal cleanup.

10 Steps for site owners to consider when performing their next portal cleanup:

  1. Remove obsolete or unnecessary sites – Sites where all content pages/documents have not been updated for 2 or more years are candidates.
  2. Examine all pages for duplicate or obsolete content and update or remove – This could result in removing the page itself if all content on the page is obsolete and removed.
  3. Remove obsolete/duplicate documents/files – Multiple instances of files all get indexed and results in bloating the search results with many invalid entries that do not point to the most recent data. Delete obsolete/duplicate files.  Burn copies onto a DVD if you want to keep them.  Adding them to your intranet site or collaboration site is not a valid solution.
  4. Remove content that appears on other sites for your organization that you do not own – Copying/duplicating content that appears on other sites within your organization bloats search results and diminishes the relevance rating of the correct document if multiple occurrences exist.  Any content not ‘owned’ by the department should be removed and replaced with a link to the content on the ‘true’ owner’s site.
  5. Remove content found on sites outside your organization – Not only is this a potential copyright issue, but updates made to the content on the ‘true’ source will not be reflected in the copied content resulting in misinformation.  Just link to external content.
  6. Clean out your calendar/announcements – If your site has a calendar or an announcements list, clean out old events that are no longer relevant.  This will improve the performance of the calendar and/or announcement list.
  7. Consolidate sites – Sometimes subsites were create when all that was needed was another page on the site that owns the subsite (parent site).  Unless the subsite requires a different set of permissions (owners, content managers, approvers, etc.) you may be able to simplify your site structure by moving content/pages/documents up a level.  This will also improve navigation and reduce the number of clicks to find the content you need.
  8. Remove content that really does not need to be public – For any content item (subsite/page/document) ask yourself if anyone in the public really needs to see this content on a public web site or whether it just clutters the public facing sites with content that no one really looks at.  Perhaps all you need is a ‘Contact Us’ link for anyone in the public to request additional information if necessary.  Some current public content probably should only be internal intranet content.  If so, move it there if it does not already exist and delete the public version.
  9. Do not duplicate content between the Internet and intranet – If the content needs to be seen by both the public and organization’s employees, place the content on the Internet and only add links to that content from the intranet. Don’t place the content on both and definitely don’t place the content only on the intranet.
  10. If content is not owned, remove it – If you have current Internet content that is not officially owned consider removing it.  Content that is not owned probably is not updated.  If the content is necessary, an owner for the content must be identified.

Well, that’s it for this time. C’ya.

The Sky is Not Falling

This week an article was published on CIO.com by Jonathan Hassell entitled, ‘7 Things CIOs Should Know About SharePoint Server 2016’. This article found it way circulating around our company from several vendors hoping to convert our SharePoint portal over to their system. They point to various statements about the new SharePoint as evidence that it is time to switch from SharePoint now. I call this ‘The Sky is Falling’ syndrome. Vendors of third party products are using it specifically to freak out SharePoint users to get them to switch to their company’s product.  However, the truth is rather different for existing SharePoint users.  Here is my personal response to some of these statements.  Don’t fall for ‘The Sky is Falling’ sales tactics.

  1. SharePoint Server 2016 might be the last version of SharePoint designed to run on premises.

    Jeff Teper just took over SharePoint at Microsoft last year and has been rebuilding the SharePoint team from the disaster it was in 2014 and early 2015.  At the European SharePoint Conference and the Microsoft MVP conference in November of 2015, a very different picture of the future of SharePoint emerged.  He has not said that Microsoft is abandoning SharePoint.  However, the definition of ‘last version’ is muddy. I believe it is more like what Microsoft has said concerning Windows 10 being the last version of the OS for PCs.  Really?  What does that really mean?  It means that all future updates will be done through regular updates/patches/etc. Haven’t they already done that with Windows 10?  In fact, the Release Candidate for SharePoint 2016 was released, I believe, as a patch to test this capability in SharePoint.  It updated our Beta 2 installation without shutting SharePoint down or reinstalling everything.  Last release?  I guess that depends on what you call a release.  It may be the beginning of the end of release numbers as we once knew them. It is a very different release world coming about.

  2. There will no longer be a free version of SharePoint for smaller shops or department use.

    True, but that is because the free release was collaboration only and that functionality has moved to SharePoint online as part of select Office 365 subscriptions where they call it Team sites.  You can also apparently buy SharePoint online as a standalone offering for $5.00 per user per month. Note that like WSS 3.0, these sites are meant for internal collaboration, not for the creation of public facing web sites.

  3. Excel Services has vanished, and to get Excel functionality, you must use Office Online Server

    Again a good choice to provide the latest updates as soon as possible.  Excel is an office product and will be baked into the Office 365 subscriptions.  Also Microsoft is pushing a new product for data analysis called Power BI which appears to be part of select Office 365 subscriptions although you can get a desktop version for free.  Gartner recently ranked Microsoft’s Power BI as most innovative in the upper right quadrant in their recent Magic Quadrant for Business Intelligence and Analytics Platforms.

  4. Managing SharePoint from the command line is pretty much a PowerShell-only affair these days

    This was announced years ago as a goal for all Microsoft servers.  There is better control over administration of Exchange and even standard Windows servers using PowerShell.  Our team has been honing our PowerShell skills for at least the last 4-5 years because we knew this was coming.  Also the SYSADM functionality was awkward at best. For some time, you have been able to install a Windows Server as a Server Core only version that skips the GUI to provide better performance and a smaller footprint which uses PowerShell for administering the server.  This direction for servers is not new for Microsoft. They gave substantial warning that administrators need to learn PowerShell in the near future.

  5. The migration process to SharePoint 2016 will be a bit involved, depending upon from where you are starting.

    While it is true that out of the box that migration from anything other than SharePoint 2013 is not directly possible, there are tools companies like ShareGate, Metalogix, and AvePoint to name just a few that support migration between SharePoint 2010, SharePoint 2013, SharePoint 2016, and SharePoint online so this is a non-issue.

  6. The Microsoft workflow and forms solution InfoPath is now Moribund

    Microsoft has promised support for InfoPath until at least 2026.  However, I do not expect Microsoft to completely eliminate support until they or a third party comes up with a viable alternative and path to get there.  Their attempt at a different forms solution in 2014-2015, Forms on SharePoint List (FoSL) failed and was removed from SharePoint 2016 until a new solution is obtained.  Unfortunately, they released the news that InfoPath was going to end prematurely without that replacement solidly in place.  In the meantime, there are other third party forms tools like K2 for SharePoint which provides a forms and workflow alternative that might be a reasonable alternative if you feel you need to start converting to something else now.

  7. There is a big focus on hybrid connectivity in SharePoint Server 2016.

    Very true because the vast majority of companies that responded to one survey expressed an interest in a hybrid approach in the future, the bottom line is that today 49% of a recent survey from Rencore use SharePoint Server on premises only, 24 % use SharePoint Online only and 25% that use a “Hybrid” configuration. Because 64% of the survey respondents also use Office 365 currently, I suspect that the percent of hybrid might increase in the near future. One factor that will keep on premise going for some time is the need to perform customizations which are easier when you have local control over the server. Over the much longer term, will hybrid on Online continue to grow at the expense of the on premise only installations, probably.

Finally I want to address the removal of public facing SharePoint sites from the Online version of SharePoint. While I have not heard anything definitive about the reasons for this decisions, I suspect the reasons are either technical (branding) or licensing related or both. I suspect at some point, Microsoft will either resolve these issues and add public facing SharePoint sites back or they will create an entire new product that will allow for the creation and support of public facing sites hosted from their online Office offerings.

In the meantime, I will strongly resist the cry that ‘The Sky Is Falling!’ and focus on things that I can control.

C’ya next time.