Quantcast
Channel: TechNet Blogs
Viewing all 36188 articles
Browse latest View live

Outlook で既定のフォントを変更する方法

$
0
0

こんにちは。日本マイクロソフト Outlook サポートチームです。

Outlook  2016 からメールを作成する際の既定のフォントが游ゴシックに変更されたため、初期値のみを以前のバージョンと同じフォントに変更したいというお問い合わせをいただくことが多くありましたので、本ブログではその方法についてご紹介いたします。

 

(1) Outlook の既定のフォントの設定場所と設定値の保存場所

Outlook の既定のフォントの設定は、 [署名とひな形] ダイアログで設定可能です。

本 UI から設定した情報は以下の「レジストリ」に保持されます。

 

Outlook UI の設定箇所

  1. [Outlook]の[ファイル] タブをクリックし、[オプション] をクリックて [Outlook オプション] ダイアログを表示します。
  2. [Outlook オプション] ダイアログの画面左側で [メール] をクリックし、画面右側で [ひな形およびフォント] をクリックします。
  3. [署名とひな形] ダイアログの [ひな形] タブをクリックします。

fontsettingsUI

■レジストリ

[ひな形] タブの以下のそれぞれで開いたダイアログの [フォント] タブで設定した "フォントの種類" "サイズ" "色" などが 2  つのレジストリ値に保持されます。

 

a.[新しいメッセージ] の [文字書式]をクリックして開いたダイアログ

b.[返信/転送メッセージ] の [文字書式]をクリックして開いたダイアログ

c.[テキスト形式のメッセージの作成と読み込み] の [文字書式]をクリックして開いたダイアログ

 

レジストリキー:

HKEY_CURRENT_USERSoftwareMicrosoftOffice16.0CommonMailSettings

 

値の名前 :

a.[新しいメッセージ] の [文字書式]

ComposeFontComplex

ComposeFontSimple

 

b.[返信/転送メッセージ] の [文字書式]

ReplyFontComplex

ReplyFontSimple

 

c.[テキスト形式のメッセージの作成と読み込み] の [文字書式]

TextFontComplex

TextFontSimple

 

値の種類 : REG_BINARY

値 : UI から指定した設定が値として保持されます。

 

(2) 既定として設定したいフォントの準備

まずは、実際に既定のフォントとして展開したいフォント情報がどのようなレジストリ値で保持されるかを Outlook がインストールされている端末で確認します。

 

Outlook クライアントでの作業 (レジストリの確認)

  1. Outlook 2016 を起動し、 [ファイル] タブ-[オプション]-[メール]-[ひな形およびフォント] ダイアログで、「日本語用のフォント」と「英数字用のフォント」のフォントの種類、サイズ、色などを設定し、ダイアログを閉じます。
  2. Outlook を終了します。
  3. OS の [ここに入力して検索] で regedit と入力し、レジストリ エディターを起動します。
  4. HKEY_CURRENT_USERSoftwareMicrosoftOffice16.0CommonMailSettingsに移動し、フォント設定の情報が保持されている MailSettings 上を右クリックし、[エクスポート] をクリックして任意の場所に .reg としてエクスポートします。
  5. エクスポートしたフォント設定のレジストリ情報は、(3) のグループ ポリシーで展開する際に参照します。

 

■エクスポートしたフォントレジストリのサンプル

エクスポートしたレジストリファイルでは、値の情報として “ hex:”、カンマ、円マーク、スペースなどが含まれていますが、グループ ポリシーのレジストリ配布機能で展開する場合、それらの文字列を除いた値を指定する必要があります。

fontreg

 

(3) レジストリを グループ ポリシー (GPO) で展開する方法

Active Directoryグループ ポリシーのレジストリの配布機能でクライアント端末に展開することが可能です。

 

■ フォントのレジストリの配布手順

  1. DC サーバーでグループ ポリシー管理エディターを起動します。
  2. [ユーザーの構成]-[基本設定]-[Windows の設定]-[レジストリ] を選択します。
  3. 同コンソールの [操作(A)]-[新規作成(N)]-[レジストリ項目] メニューを実行します。
  4. [新しいレジストリのプロパティ] ダイアログの [全般] タブにおいて、各項目の値を以下の様に選択、あるいは入力します。
    以下は a.[新しいメッセージ] の [文字書式] の [日本語用フォント] を設定するレジストリ例です。アクション: 更新
    ハイブ: HKEY_CURRENT_USER (既定のまま)
    キーのパス: SoftwareMicrosoftOffice16.0CommonMailSettings (レジストリパスを直接入力します)
    値の名前: ComposeFontComplex
    値の種類: REG_BINARY
    値:  以下のような値で指定します。
    3c68746d6c3e0d0a0d0a3c686561643e0d0a3c7374796c653e0d0a0d0a202f2a205374796c6520446566696e6974696f6e73202a2f0d0a207370616e2e610d0a097b6d736f2d7374796c652d6e616d653a5c373245435c383145415c333036455c344635435c363231305c333042395c333042465c333041345c333045423b0d0a096d736f2d7374796c652d747970653a706572736f6e616c2d636f6d706f73653b0d0a096d736f2d7374796c652d6e6f73686f773a7965733b0d0a096d736f2d7374796c652d756e686964653a6e6f3b0d0a096d736f2d616e73692d666f6e742d73697a653a31302e3070743b0d0a096d736f2d626964692d666f6e742d73697a653a31312e3070743b0d0a09666f6e742d66616d696c793a22417269616c222c73616e732d73657269663b0d0a096d736f2d61736369692d666f6e742d66616d696c793a417269616c3b0d0a096d736f2d666172656173742d666f6e742d66616d696c793a224d5320476f74686963223b0d0a096d736f2d68616e73692d666f6e742d66616d696c793a417269616c3b0d0a096d736f2d626964692d666f6e742d66616d696c793a2254696d6573204e657720526f6d616e223b0d0a096d736f2d626964692d7468656d652d666f6e743a6d696e6f722d626964693b0d0a09636f6c6f723a77696e646f77746578743b7d0d0a2d2d3e0d0a3c2f7374796c653e0d0a3c2f686561643e0d0a0d0a3c2f68746d6c3e0d0a
    ※ここで指定する値は (2) の「 既定として設定したいフォントの準備」でエクスポートしたレジストリの値を元に設定してください。
    エクスポートしたレジストリファイルには、上述のスクリーンショットのように値の情報として含まれている “ hex:”、カンマ、円マーク、スペースなどがありますが、それらを除いて指定する必要があります
  5. [共通] タブで “1 度だけ適用し、再適用しない” のチェックをオンにします。
    ※ 1  度だけ適用にすることで、初期値だけ共通のフォントとして展開でき、その後各ユーザーが Outlook の UI から任意にフォントを変更した場合、ユーザーが設定したフォントが使用できる動作となります。本設定を指定しない場合は、GPO がクライアント端末に適用されるたびに、GPO で展開したフォント設定に戻ります。
  6. 設定が終了したら [OK] で終了します。
  7. 手順を繰り返し、既定のフォントとして展開したい以下の各レジストリを必要に応じて合計 6 個設定します。

    - フォント設定のレジストリ
    a.[新しいメッセージ] の [文字書式]
    ComposeFontComplex
    ComposeFontSimple
    b.[返信/転送メッセージ] の [文字書式]
    ReplyFontComplex
    ReplyFontSimple
    c.[テキスト形式のメッセージの作成と読み込み] の [文字書式]
    TextFontComplex
    TextFontSimple

以上が、既に Outlook を一度は起動したことがある端末に配布する場合の手順です。
Outlook を一度も起動したことのない端末にも初期フォントの設定を展開する必要がある場合には、フォントのレジストリと同様の手順で以下のレジストリも一緒に配布してください。

■ Outlook を一度も起動したことがないユーザーにも設定を反映させるためのレジストリ

ご使用の Office にあわせて以下の A または B を設定してください。両方のレジストリを配布しても問題はありません。

 

A.Office 2016 の MSI 版をご利用の場合

レジストリキー: HKEY_CURRENT_USERSoftwareMicrosoftOffice16.0CommonLanguageResources

値の名前: OutlookChangeInstallLanguage

値の種類: REG_SZ

値:YES

※本来クイック実行版ではこのレジストリの配布は必須ではございませんが、Office のインストール言語 (言語パックなどのインストール) によっては本レジストリが「値 No」で存在する場合があります。

その場合は Yes に変更する必要がありますので、レジストリが存在するか事前にご確認ください。

 

B.Office 2016 クイック実行版 (C2R) 版をご利用の場合

レジストリキー : HKEY_CURRENT_USERSoftwareMicrosoftOffice16.0CommonLanguageResources

値の名前 : LangTuneUp

値の種類 : REG_SZ

値 : OfficeCompleted

 

(4) その他情報

  • Office グループ ポリシー管理者用テンプレートでは Outlook の既定のフォント設定を制御するためのテンプレートは提供しておりません。本ブログにあるレジストリを配布する方法で展開をご検討ください。
  • 以下にご参考情報として Outlook 2013 の既定のフォント設定を記載しました。
    a.[新しいメッセージ]
    日本語用のフォント - MS ゴシック (MS Gothic)
    英数字用のフォント - Arial
    サイズ - 10
    b.[返信/転送メッセージ]
    日本語用のフォント - MS ゴシック (MS Gothic)
    英数字用のフォント - Arial
    サイズ - 10
    c.[テキスト形式のメッセージの作成と読み込み]
    日本語用のフォント - MS ゴシック (MS Gothic)
    英数字用のフォント - (日本語用と同じフォント)
    サイズ - 10

Explore Microsoft’s Redmond Campus In Minecraft:Education Edition

$
0
0

Have fun exploring the massive Redmond Campus, home to many thousands of Microsoft's employees

If you've ever wanted to explore the massive Microsoft Redmond Campus but never had a chance (or permission!) can you now do this via Minecraft:Education Edition with a world provided by Microsoft Facilities (note: there is no support associated in anyway with this world).

Download Minecraft;EE Redmond Campus World here

According to Wikipedia,

It is estimated to encompass over 8 million square feet (740,000 m2) of office space and 30,000–40,000 employees.

If you're new to Minecraft:Education Edition, you may way to read my Ultimate Setup Guide to help you get underway. To get started with the above you need to first download the file and import the world into Minecraft:EE

Once you have the downloaded file you can simply double click it and this will launch Minecraft:EE and start the import into your list of worlds

Once the import has finished you should see the Microsoft Campus world showing alongside your available worlds to play

It's worth noting that the current template file is saved in "Creative Mode" - this means that you can be destructive inside the world (or creative and build new proposed buildings for Microsoft!).

If you're a teacher and you would prefer your students didn't start destroying the buildings as soon as they're in there, you may want to open the world in "Survival Mode" which will prevent this:

When you are first inside the world you are presented with a Campus Map making it that little bit easier to decide where to go exploring first:

Note the green dot (I've circled it in red) shows you were you are - I've also highlighted the cricket pitch - more screenshots below!

For Microsoft employees there are some fun quizzes that can be played inside the world (below) - these could be a bit challenging for the average student, but perhaps you could use this as a challenge to try and find answers for during the upcoming Skype-a-thon, a fun annual activity where Microsoft employees skype with students in schools around the world.

Quizzes in the game

Another useful feature of the Campus World is the use of NPC (Non Playing Characters) who provide interesting facts about that particular area of the Campus:

One of the main thoroughfares on the campus - there are stores, eateries and even Microsoft colour-themed flags!

When I first visited the Redmond Campus I was struck by it's size - unfortunately Redmond was experiencing a rare snowy day so it was a bit cold to wander too far afield, however I did come across the soccer fields (people were playing soccer on it under lights with snow on the ground!):

What's interesting is that as Microsoft's employee makeup has diversified, so has the recreation pastimes offered. There is now a cricket field on campus as well:

 

And it would not be America without a baseball diamond:

This is a fun Minecraft:EE world to explore and I encourage you to download it and have a look around!

Build your technical capabilities for Teamwork solutions

$
0
0

Are you looking to expand your Teamwork solution skills? Join these new technical webinars {available at no cost to MPN members} and increase your Teamwork technical confidence with guidance from Microsoft Partner Technical Consultants.

Introduction to Firstline Worker Solutions

  • This webinar will help you understand the strategy of approaching Firstline Worker engagement on up to two specific industries. This will be done by looking into Service and Task worker roles as example by demonstrating their day to day work. Firstline workers are in roles with well-defined responsibilities and can be a customer’s first point of contact, making product or managing operations. This type of work is typically more specific to industries such as retail, manufacturing and hospital.

What’s New in Office 365 Teamwork Solutions

  • Teamwork Solutions in Microsoft 365 continues to rapidly evolve. This technical webinar series will assist MPN partners in staying up-to-date on the newest developments and service abilities, feature updates and releases. The information presented will be mostly technical in nature, but occasionally our Microsoft technical experts will provide marketing and business news pertaining to building a cloud practice. During this webcast, you may also ask questions as they pertain to your practice.

Adopting Microsoft Teamwork Solutions: Mail & Messaging

  • Assist customers looking to migrate their messaging infrastructure to Office 365. Whether their mail service is on-premises or in the cloud, you’ll learn about the different migration paths available and understand the best method for getting them to Exchange Online. Mail and Messaging are critical elements of Teamwork Services and often form the communications backbone for many organizations. Understanding the role of these services and how to confidently propose updates and modernization is an important part of a Partner's portfolio.

Explore the full suite of technical webinars and consultations available for the Teamwork technical journey at aka.ms/TeamworkTechJourney.

[ウェビナー] いそがしいひとのためのMicrosoft Ignite 2018【10/19更新】

$
0
0

2018年10月24日(水) 16:30-17:30

<概要> 9/24-28に米国 Orlando で開催される今年最大級の技術カンファレンス Microsoft Ignite 2018 で発表された内容のうち、Data & AI のカテゴリにフォーカスし、最新情報をまるっとキャッチアップする1時間です。おたのしみに!

 

 

お申込みはこちら

 

 

 

 

 

 

Microsoft Technical Day – online přenos, 8. 11. 2018

$
0
0

Zveme vás na on-line přenos hlavní části konference Technical Day.
Vystoupí na na přední odborníci z oblasti bezpečnosti a umělé inteligence.

Inspirujte se nejnovějšími trendy a poslechněte si, jak přistupovat k nastavení bezpečnostní strategie vaší organizace. Představíme vám také naše nové produkty a technologie, které byly uvedeny v rámci konference Microsoft Ignite.

9:00
Úvodní slovo: Bezpečnost a soulad s předpisy – Zděněk Jiříček, Chief Technology Officer, Microsoft
Kromě všech výzev, které bezpečnost má po technologické stránce dopadají na IT i požadavky vyvolané státními orgány a regulátory trhu. Proč je důležité tuto oblast nezanedbat.

9:15
Anatomie hackerských útoků: Pohled do budoucnosti kybernetické bezpečnosti - Paula Januszkiewicz, CEO, CQURE, Security Expert
Světoznámá odbornice na zabezpečení IT se ve své přednášce zaměří na aktuální i budoucí výzvy v oblasti zabezpečení IT, zranitelná místa, nejčastější útoky hackerů a jakým způsobem se jim bránit.

10:00
Bezpečnost IoT - Štěpán Bechynský, Azure IoT TSP, Microsoft
Bezpečnost IoT je v tuto chvíli velmi blízká nule. Velké množství připojených zařízení není aktualizováno na bezpečnostní hrozby nebo je úplně nezabezpečených. V přednášce si ukážeme základní principy bezpečnosti u IoT zařízení a navazujících cloudových služeb.

11:00
Umělá inteligence jako katalyzátor digitální transformace v různých odvětvích - Dmytro Turchyn, Artificial Intelligence PMM, Microsoft
Umělá inteligence přináší doposud nepoznané možnosti a je zdrojem významné inovace a digitální transformace v mnoha odvětvích. Představíme vám nejčastější oblasti využití služeb umělé inteligence dostupné v Microsoft Azure a také praktické scénáře využití těchto inteligentních služeb.

11:30
Podzimní přehled klíčových novinek – Petra Váša, Microsoft 365 Business Group Lead, Microsoft
Představení nových produktů a technologií, které byly uvedeny v rámci konference Microsoft Ignite na konci září.

Pro přístup k live straemu je třeba se registrovat zde : www.aka.ms/technicalday

 

It always starts with the “Why”– In der Cloud muss man Dinge einfach mal anders machen!

$
0
0

Heute möchte ich euch von einem Erlebnis von mir erzählen - wer meinen Blog verfolgt weiß, dass ich normalerweise eher sachlich bin - da mir dieses Thema aber persönlich wichtig ist schreibe ich hier mal die Ausnahme von der Regel:

In unserer Eventreihe "Road to Modern Work(shop)" - kurz es geht dabei darum, dass ein Kunde mit dem Partner seiner Wahl zu uns kommt und wir (Kunde+Partner+Microsoft Experte) uns über ein konkretes Problem Gedanken machen und dabei am Ende eine gemeinsame Lösungsidee/architektur herauskommt - war einem der letzten Termine bei mir am Tisch folgende Problemstellung:

"Wenn ich mit Exchange Online (EXO) in die Cloud gehe, wie gehe ich dann mit dem Backup um? Bevor ich da nicht aussagekräftig bin werden wir nicht migrieren."

Die Fragestellung ist absolut valide und im ersten Moment auch recht schnell beantwortet, denn neben den Zusagen von Microsoft hinsichtlich Verfügbarkeit, gibt es unterschiedliche Partnerlösungen, die Backup u.a. in EXO abbilden können.

Also im ersten Moment ein schneller Termin - doch halt! In der Microsoft Tech Community haben wir ein Mantra, das da heißt:

"In der Cloud muss man Dinge anders machen!"

(mit der Ergänzung: "sonst spart man kein Geld" oder "sonst ist man nicht effizienter/produktiver")

Um Dinge anders machen zu können, muss man zum einen das Ziel kennen und zum anderen vor allem auch die Beweggründe, warum bestimmte Dinge bis jetzt so gemacht werden/wurden wie sie eben gemacht werden/wurden.

Dazu dient ein einfaches Hilfsmittel und das heißt

"Warum?"

(Oder wer gerne singt: 🎶"Wer, wie, was - wer, wie, was - wieso, weshalb, warum - wer nicht fragt bleibt on-premise"🎶)
Und das so lange, bis alle Handlungen und Hintergründe offen auf dem Tisch liegen!

 

Daher fragte ich also: "Warum macht ihr aktuell eigentlich die Backups - welchen Schmerz behebt ihr damit und wie häufig braucht ihr das eigentlich?"

Die Antwort war schnell gefunden: "Weil die User Emails löschen und nach der Speicherdauer im Papierkorb dann manchmal (=selten) doch noch mal darauf zugreifen wollen."

 

Schön. Aber ich folgte natürlich brav unserem Hilfsmittel: "Warum löschen denn die User eigentlich die Mails?"

Mit der Frage haben wir uns länger beschäftigt, sind aber schlussendlich auf den Hintergrund gekommen und dies brachte dann auch gleich eine Erkenntnis mit: "Weil das Postfach zu klein ist und sie zwangsweise Mails löschen müssen… oh..."
(Der Vollständigkeit halber: die Postfächer dort hatten 3, 5 oder 7 GB und mit EXOP2 bzw. O365E3 bzw. M365E3 haben die neuen Postfächer 100GB!)

 

Sprich durch das Hinterfragen der Beweggründe sind wir darauf gekommen, dass für die meisten der betroffenen User lediglich eine Verhaltensänderung - nämlich nicht mehr zu löschen - notwendig ist und die Aufwendungen für - in diesem Fall - Backup klar zu hinterfragen sind, da die Ursache der Ursprungshandlung durch die Migration entfällt. [Disclaimer: natürlich gibt es noch andere Gründe aus denen ein Backup notwendig sein könnte, das muss jeder für seine Situation selbst entscheiden, das soll also kein Aufruf sein alle Backups sein zu lassen!]

Dieser Fall zeigt also klar drei Dinge:

  1. Es beginnt immer mit dem "Warum"
  2. In der Cloud muss man Dinge anders machen um erfolgreich zu sein!
  3. Was soll danach besser sein/ welchen Schmerz wollt ihr beheben?

Hyper-V レプリカと Windows Server バックアップを併用する際の注意点

$
0
0

こんにちは。
Windows プラットフォーム サポート担当の佐々木です。
今回は、Hyper-V レプリカと Windows Server バックアップを併用する際に、レプリケーションが停止する事象についてご案内させていただきます。

■レプリケーションとは?

コンピュータやソフトウェアの管理するデータと同じ内容のレプリカ(複製)を作成することです。
ホストサーバのデータ情報と作成したレプリカの内容を定期的に同期するため、万が一ホストサーバに障害が発生した場合でも、
作成したレプリカからシステムを稼働し続けることができます。
そのため、レプリケーションを行うことでシステムの高可用性を高めることにつながります。

■Hyper-V レプリカとは?

Hyper -V レプリカは、 Windows Server 2012から実装された Hyper-V の機能の一部です。
Hyper-V ホストで作成した仮想マシンでHyper-Vレプリカの機能を有効にすると、
Hyper-Vホストの仮想マシンのレプリカがHyper-V レプリカに作成され、随時レプリケーションを行うことができます。

■対象 OS

Windows Server 2012
Windows Server 2012 R2
Windows Server 2016

■Hyper-V レプリカと Windows Server バックアップを併用する際の注意点

Windows Server 標準の Windows Server バックアップでは Hyper-V レプリカ環境のバックアップには対応しておりません。

そのため、Hyper-V レプリカでレプリケーションを行っている際に
Windows Server バックアップにて仮想マシンのバックアップを実行すると
Hyper-V レプリカとHyper-V ホストのレプリケーションが切断される事象が発生することがございます。

■対応策

Hyper-V レプリカに対応したバックアップアプリケーションのご利用をご検討ください。
弊社製品では、System Center Data Protection Manager (DPM) 2012 R2 以降のバージョンから対応しております。

また、以下の2点を考慮することで回避することができます。

①バックアップの開始前にレプリケーションを一時停止する。
②バックアップ完了後、レプリケーションを再開する。

※レプリケーションの再開 / 一時停止は、以下の PowerShellコマンドにより実行することができます。

レプリケーションの再開  :Resume-VMReplication
レプリケーションの一時停止:Suspend-VMReplication

参考:
Hyper-V 仮想マシンのバックアップ
https://docs.microsoft.com/ja-jp/system-center/dpm/back-up-hyper-v-virtual-machines?view=sc-dpm-1807

Suspend-VMReplication
https://docs.microsoft.com/en-us/powershell/module/hyper-v/suspend-vmreplication

Resume-VMReplication
https://docs.microsoft.com/en-us/powershell/module/hyper-v/resume-vmreplication

いかがでしたでしょうか。
本ブログが少しでも皆様のお役に立つと幸いです。

本情報の内容(添付文書、リンク先などを含む)は、作成日時点でのものであり、予告なく変更される場合があります。

[Power BI] DAX入門 (1) まずはここを見よう リンク集

$
0
0

この記事は、2016 年 6 月 20 日 に Data Platform Tech Sales Team Blog にて公開された内容です。

 

Microsoft Japan Data Platform Tech Sales Team

土井

■DAX とは

Data Analysis Expressions (DAX) 言語は、Microsoft SQL Server Analysis Services (SSAS) や Excel の Power Pivot、Power BI Desktop で数式や式を作成するための部品として使用できる関数や演算子のライブラリです。DAX にはさまざまな種類の関数があり、 たとえば前年比の算出やカレンダーテーブルの作成などに必要なタイムインテリジェンス関数や IF, SWITCH などの論理関数、COUNT, RANKX などの集計関数等があります。

Excel ライクに記述が可能なため、比較的馴染みやすいのが特徴ですが、とはいえ、DAX の基本的な使い方や関数の一覧についてなかなかまとまった情報が見つかりにくい、というお問合せをよくいただくため、今回はまず第一弾として参考になるであろう各種リンクのご紹介を致します。

■日本語ナレッジ

[Data Analysis Expressions (DAX) リファレンス]
https://msdn.microsoft.com/library/gg413422.aspx
まずは何といっても公式のリファレンスです。慣れてくるとこのリファレンスが一番しっくりきますが、はじめて触る方にとっては少しハードルが高いかもしれません。中級~上級者向けです。
 

[Power BI Desktop における DAX の基本事項]
https://powerbi.microsoft.com/ja-jp/documentation/powerbi-desktop-quickstart-learn-dax-basics/
Power BI Desktop における、とありますが、SSAS や PowerPivot でも同様です。初心者向けの内容になってます。
 

[SQL Server 自習書 Analysis Services によるインメモリ BI 入門] (PDF)
http://go.microsoft.com/?linkid=9820057
P.75 (3.4 DAX 式を利用したメジャーの作成(比率や前年金額などの計算)) あたり。初心者向けです。
 

[Power BI Desktop を使って訪日外国人 (インバウンド) 統計データを可視化する]
http://blogs.msdn.microsoft.com/dataplatjp/?p=995
よく使う累計や前年比について触れています。サンプルファイルもダウンロードいただけます。初心者向けです。
 

■英語ナレッジ

[DAX Resource Center]
http://social.technet.microsoft.com/wiki/contents/articles/1088.dax-resource-center.aspx
DAX に関連する各種リソースをまとめています。Excel 2010 PowerPivot に関する内容が多いですが、SSAS や Power BI Desktop でも問題なく利用できます。
 

[DAX in the BI Tabular Model Whitepaper and Samples]
https://www.microsoft.com/en-us/download/details.aspx?id=28572
上記のリソースセンターの中で、有用と思われるサンプルコンテンツです。PowerPivot のサンプルファイルと、ホワイトペーパー 「Data Analysis Expressions (DAX) In PowerPivot for Excel 2010」 をダウンロードできます。
 

[Dax Patterns]
http://www.daxpatterns.com/usecases/
逆引きで DAX パターンを調べることができます。Excel 2010, 2013 のサンプルファイルもダウンロードできます。
 

■英語動画

[DAX 101] 初心者向け
https://www.youtube.com/watch?v=klQAZLr5vxA
 

[Advanced DAX ] 上級者向け
https://www.youtube.com/watch?v=6ncHnWMEdic
 

[Analyzing and Visualizing Data with Excel] 初心者向け
https://mva.microsoft.com/en-US/training-courses/analyzing-and-visualizing-data-with-excel-11157?l=OXUnAHXPB_2505095270

Topic2 The Excel Data Model and Basic DAX 8:50
Topic5 Advanced DAX 12:25

PowerPivot にフォーカスした内容です。字幕をオンにすることもできます。
 

■まとめ

第一弾では各種リンクの紹介をいたしました。今後、よく使われる関数について具体的な使い方について記事を書いていきたいと思っていますので、ご期待ください。

関連記事
DAX 入門
https://blogs.msdn.microsoft.com/dataplatjp/dax/
 


[Power BI] DAX入門 (2) カレンダーテーブルの作成

$
0
0

この記事は、2016 年 7 月 11 日 に Data Platform Tech Sales Team Blog にて公開された内容です。

 

Microsoft Japan Data Platform Tech Sales Team

土井

DAX 入門 第二回目では、カレンダーテーブルを生成するための日付と時刻の関数と、それに付随して文字列関数と論理関数について具体的に触れていきます。 (本記事で作成するサンプルファイルは こちら からダウンロードいただけます。)

■なぜカレンダーテーブルが必要か

カレンダーテーブルを作成することで、年ごと、四半期ごと、月ごと、週ごと、といった形で任意の時系列単位でデータを集計することが可能になります。同様の意味で、 "タイム ディメンション" と言ったり、"時間階層" と言ったり "日付マスタ" と言ったりしますが、ここでは "カレンダーテーブル" として統一します。

Power BI Desktop や PowerPivot も含め、多くの BI ツールでは 分析に使用するデータの中に date 型の列があれば、カレンダーテーブルを自動的に (暗黙的に) 作成する機能を持っていますが、意図した仕様とは異なったものになっており、結局イチからカレンダーテーブルを作成しないといけない、といったことも多々あります。たとえば一週間の曜日始まりを月曜として週単位で集計したいのに、日曜始まりとなってしまっていたり、曜日表記を英語ではなく日本語で表示したかったり、前年同日ではなく前年同曜日を算出したいといった場合等が挙げられます。
 

■CALENDAR 関数

CALENDAR 関数 は SQL Server 2016 Analysis Services (SSAS), Power Pivot in Excel 2016, そして Power BI Desktop で提供されている新しい DAX 関数で、開始日と終了日を指定して、date 型の列を生成することができます。以降、本記事では Power BI Desktop を例に進めますが、SSAS や PowerPivot でも同様のことができるようになっています。

Power BI Desktop を立ち上げて、”モデリング”タブから”新しいテーブル”をクリックします。

image

数式ペインに以下の式を入力します。

カレンダー = CALENDAR("2015/1/1", TODAY())

image

TODAY 関数 は現在の日付を返します。時刻は 0:00:00 となります。

類似の関数として NOW 関数 があります。こちらは時刻もその時点の時刻として反映されます。Power BI Service でスケジュール更新されるレポートに更新日時を表示する際等に最適です。
 

新しいテーブルが作成され、2015/1/1~本日までの date 型の列を持つテーブルが作成されました。

image
 

■日付と時刻の関数

さきほど作成した Date 列を基に、集計したい単位の列を DAX 関数を使って生成します。日付と時刻の関数 (DAX) の中から以下の関数を使用します。
 

YEAR 関数 ・・・ 日付の年を 4 桁の整数として返します。範囲は 1900 ~ 9999 です。

年 = YEAR([Date])

 

MONTH 関数 ・・・ 1 (1 月) から 12 (12 月) までの数値として月を返します。

月番号 = MONTH([Date])

 

WEEKDAY 関数 ・・・ 日付に対応する曜日を return_type 値に従って返します。 既定では、曜日の範囲は 1 (日曜日) ~ 7 (土曜日) です。

曜日番号 = WEEKDAY([Date], <return_type>)
return_type 週の始まり
1 (既定) 週の始まりを日曜日 (1)、終わりを土曜日 (7) とします。
2 週の始まりを月曜日 (1)、終わりを日曜日 (7) とします。
3 週の始まりを月曜日 (0)、終わりを日曜日 (6) とします。

 

WEEKNUM 関数 ・・・ 特定の日付が第何週目に当たるかを返します。 たとえば、1 月 1 日を含む週がその年の最初の週で、第 1 週になります。

この関数で使用されるシステムには、次の 2 種類があります。

  • システム 1 1 月 1 日を含む週がその年の最初の週であり、第 1 週です。
  • システム 2 その年の最初の木曜日を含む週がその年の最初の週であり、第 1 週です。 このシステムは、ヨーロッパ式週番号システムと呼ばれる、ISO 8601 に規定されている方式です。
週番号 = WEEKNUM([Date], <return_type>)
return_type 週の始まり システム
1 or 17 (既定) 日曜日 1
2 or 11 月曜日 1
12 火曜日 1
13 水曜日 1
14 木曜日 1
15 金曜日 1
16 土曜日 1
21 月曜日 2 (ISO week date)

※WEEKNUM 関数については Excel 関数におけるガイド も合わせて参照ください。
 

上記 4 つの DAX 関数を使って、Power BI Desktop で新しい列 を作成すると、以下のようになります。

(ここでは WEEKDAY 関数の return_type は 2、WEEKNUM 関数の return_type は 21 としています)

image
 

■文字列関数と論理関数

文字列関数論理関数 を使って日本式なカレンダーテーブルを作成していきます。まず文字列関数の FORMAT 関数 を使って、

月 = FORMAT([Date],"M月")
年月 = FORMAT([Date],"YYYY年MM月")

を作成します。FORMAT 関数のカスタム日付/時刻書式 も合わせて参照ください。

以下のように列が追加されます。このとき、”月” 列を選択した状態で、”列で並び替え”をクリックし、”月番号”を選択します。

image

これにより、”月” 列のソート順は “月番号” 列によってコントロールされることになります。たとえば、商品名の列を商品 ID 順にソートしたい、といった場合でも同様に設定が可能です。
 

次に、論理関数の Switch 関数IF 関数 を使って日本式の “曜日”、”会計年度”、”四半期” 列を作成します。(ここでは年度始まりを 4 月としています)

曜日 = SWITCH([曜日番号], 1, "月", 2, "火", 3, "水", 4, "木", 5, "金", 6, "土", 7, "日","")
会計年度 = IF([月番号]<4,[年]-1,[年])
四半期 = IF([月番号]<4,"Q4",IF([月番号]<7,"Q1",IF([月番号]<10,"Q2","Q3")))

image

さきほどと同様に、”曜日” 列を選択して ”曜日番号” で並べ替えされるように設定しておきます。
 

最後に、冒頭で自動で生成された “Date” 列の名前を ”日付” に変更しておきます。

image

列の名前が変わっても、これまで作成してきた “Date” 列を参照した式がすべて自動で “日付”に変わるので、エラーは起きません。

image
 

■まとめ

本記事では、よく使われる DAX 関数を使ってカレンダーテーブルを作成する方法についてご紹介いたしました。論理関数や文字列関数等はカレンダーテーブル以外にも応用可能なので、是非お手元のデータで試してみてください。

なお、今回作成したサンプルファイルは こちら からダウンロードいただけます。

 

Kalenderwoche 42/2018 für IT-Experten im Rückblick: Azure Digital Twins, Azure IoT, Azure Data Studio und mehr

$
0
0

Was hat sich in der vergangenen Woche für IT-Professionals getan? Gab es wichtige Ankündigungen oder neue Wissensressourcen? Unser TechNet Blog-Team hat zehn interessante Links für Sie zusammengestellt. Viel Spaß beim Stöbern!

 

Announcing Support for Controlled Connections to Public Folders in Outlook

$
0
0

Up to now, Administrators did not have control over which users would see public folders in their Outlook clients. If public folders were created within the organization or if an Exchange Online organization is configured to access on-premises public folders, all clients would make a connection to and show the “Public folders” object in Outlook. From there, one could control access to individual public folders (controlled through folder permissions). However, it was difficult to have only some of Outlook clients connect to public folders.

We are now introducing the ability to show the public folder object in Outlook to only a set of users who might need them. To get started, this will be available for Outlook for Windows users only.

To do this, administrators can use two parameters:

  • PublicFolderClientAccess is an optional parameter on the user object. By default, its value is set to ‘false’. Setting this to ‘true’ on a specific user designates this user as one of users who will see public folders in Outlook.
  • PublicFolderShowClientControl parameter on the organization config. By default, the value of this parameter is also ‘false’ and once it is set to ‘true’, the controlled access of public folders is enabled.

Here is an example of how to use these parameters; to enable access to only the user “Administrator” and turn the feature on for the organization:

Set-CASMailbox “Administrator" -PublicFolderClientAccess $true
Set-OrganizationConfig -PublicFolderShowClientControl $true

Important note: setting the organization parameter to true without setting user attributes to true first will make it so no users will see the public folder object in Outlook for Windows. In other words – if you want to implement this, we suggest that you plan ahead and populate user attributes first (PublicFolderClientAccess on users that need access set to true) and then set the organization level parameter (PublicFolderShowClientControl set to true). That way, users who need to have access will not lose access unexpectedly.

Why would you want to do this?

Tenant admins will now have more flexibility over which users connect to public folders in Outlook. This will benefit very large organizations who might have issues with connection limits to public folders and will reduce the load to that infrastructure.

This will also be helpful to organizations during mergers and acquisitions if moving to EXO. Imagine one organization having existing public folders, but after the companies merge – without this feature all of the users would unnecessarily connect to the public folder hierarchy.

Note: This feature is not intended to be replacement for public folder permissions, it is merely providing means to have more control over which clients connect to the public folder tree.

A few more questions answered that you might be interested in:

Will this work for only Outlook on Windows?

At this time, yes. We are working to bring this to additional clients (like Outlook for Mac or Outlook on the web) in the future and will talk about this later.

What about on-premises servers?

We are considering support for on-premises in a future CUs and we will provide details at the later time.

Is there a specific version of Outlook that I need to see changed behavior?

No. The feature works by removing the public folder information from the Autodiscover response to Outlook for Windows clients. Therefore, if the user is not enabled for public folder access they will simply not connect to the public folder tree no matter the version of Outlook for Windows they use.

In case of any questions, please do reach out to us via the comments section below. We are updating official documentation to add those parameters.

Public folder team

This Blog Is Now Retired

$
0
0

Hello Everyone

We have retired this blog. We are now blogging on a new Configuration Manager blog on the Microsoft TechCommunity located here: https://techcommunity.microsoft.com/t5/Configuration-Manager-Blog/bg-p/ConfigurationManagerBlog

Join us there for informative and best practice posts from the Configuration Manager team.

To get started:

  1. Create your account on the Microsoft TechCommunity
  2. Join the System Center Configuration Manager community
  3. Follow our new blog
  4. Add your contributions and comments to our discussion space

Note: This TechNet blog will remain in place for a period to allow access to historical blog posts but no further updates will be made here.

See you over on the TechCommunity.

-Yvette

Horário de verão no Brasil 2018 – Como isso afeta o calendário de clientes do Microsoft Exchange e Office 365

$
0
0

Sobre o horário de verão 2018:
==========================================

Conforme última atualização do decreto 6658, o horário de verão brasileiro está definido da seguinte forma:
Horário de verão inicia no primeiro domingo de novembro (dia 04) às 00:00:00
Horário de verão termina no terceiro domingo de fevereiro (dia 17) às 00:00:00
Para suportar estas alterações de horário de verão, a Microsoft disponibilizou desde abril de 2018 as atualizações para as versões de sistemas operacionais suportadas.
Segue abaixo o artigo oficial sobre a atualização;
#  Time zone and DST changes in Windows for Brazil, Morocco, and São Tomé and Príncipe
https://support.microsoft.com/en-us/help/4093753/time-zone-and-dst-changes-in-windows-for-brazil-morocco-and-sao-tome-a
* É possível que outras atualizações tenham substituído esta atualização. Consultar o site do Catalog para ver o último kb válido.

Como esta mudança afeta os clientes de Exchange / Office 365?
==========================================

Os clientes de correio trabalham de maneiras diferentes.
  • Outlook: irá utilizar a informação de fuso horário da máquina local para ajustar as reuniões. Se o Sistema Operacional estiver devidamente atualizado, o Outlook irá mostrar as reuniões com o horário correto.
  • OWA: O cliente OWA utiliza as informações de fuso horário do servidor. Isto significa que usuários do OWA necessitam que a atualização de fuso horário esteja aplicada em todos os servidores Exchange da organização.
  • ActiveSync: O ajuste dos compromissos no calendário dos dispositivos móveis dependem de atualização no S.O. do próprio dispositivo.
* Os servidores do Office 365 já estão atualizados com as últimas definições de horário de verão.

Informações adicionais
==========================================

Ao criar compromissos baseados em Exchange / Office 365, a solicitação da reunião inclui informações do horário de verão do organizador da reunião, ou seja, ao criar uma solicitação de reunião de uma estação de trabalho, o Outlook vai incluir o fuso horário do organizador e informações de quando o horário de verão começa e termina. Neste caso, mesmo que você tenha uma reunião recorrente que foi criada antes de sair a atualização do horário de verão, o cliente de correio tem que ser capaz de recalcular o horário do compromisso baseado nas informações atualizadas do SO da estação de trabalho ou servidor (dependendo do cliente utilizado).
Pode acontecer em alguns casos de compromissos seguirem com a data incorreta, principalmente no período Delta (período de alteração entre a antiga data de horário de verão e a nova data – neste ano de 2018 entre 21 de outubro a 03 de novembro), como se respeitasse o horário de verão de antes da atualização. Para estes casos o melhor é avaliar os compromissos individualmente, o maior motivo para isso acontecer é alguma propriedade do compromisso estar ausente ou corrompida, que pode gerar ainda resultados distintos para o mesmo compromisso se comparados em clientes diferentes como Outlook e OWA.
Para estes casos, a recomendação é rodar a ferramenta Calendar Checking Tool for Outlook (CalCheck) no calendário afetado.
https://www.microsoft.com/en-us/download/details.aspx?id=28786
A ferramenta irá gerar um relatório no formato *.csv. Verifique se o compromisso afetado está listado no relatório. Somente compromissos com erro aparecem no relatório.
Consulte o site abaixo para ver a relação dos erros e as respectivas soluções;
https://support.microsoft.com/en-us/help/2678030/information-about-the-calendar-checking-tool-for-outlook-calcheck

Para confirmar se a atualização do horário de verão foi aplicada no Windows, você pode utilizar o comando abaixo;
Antes do KB instalado:
w32tm /tz
Time zone: Current:TIME_ZONE_ID_STANDARD Bias: 180min (UTC=LocalTime+Bias)
[Standard Name:"E. South America Standard Time" Bias:0min Date:(M:2 D:3 DoW:6)]
[Daylight Name:"E. South America Daylight Time" Bias:-60min Date:(M:10 D:3 DoW:6)]
 
Após KB instalado:
w32tm /tz
Time zone: Current:TIME_ZONE_ID_STANDARD Bias: 180min (UTC=LocalTime+Bias)
[Standard Name:"E. South America Standard Time" Bias:0min Date:(M:2 D:3 DoW:6)]
[Daylight Name:"E. South America Daylight Time" Bias:-60min Date:(M:11 D:1 DoW:6)]

Artigos relacionados:
==========================================

# Decreto Oficial com as datas de horário de verão:
https://www.planalto.gov.br/ccivil_03/_Ato2007-2010/2008/Decreto/D6558.htm
# Horário de verão no Brasil inicia em 04 de Novembro de 2018 (lista de KBs)
https://blogs.technet.microsoft.com/latam/2018/10/17/horario-de-verao-no-brasil-inicia-em-04-de-novembro-de-2018-lista-de-kbs/
# How time zone normalization works in Microsoft Outlook
https://support.microsoft.com/en-us/help/2642044/how-time-zone-normalization-works-in-microsoft-outlook
# Information about the Calendar Checking Tool for Outlook (CalCheck)
https://support.microsoft.com/pt-br/help/2678030/information-about-the-calendar-checking-tool-for-outlook-calcheck

This Blog Is Now Retired

$
0
0

Hello Everyone

We have retired this blog. We are now blogging as part of the new Configuration Manager blog on the Microsoft TechCommunity located here: https://techcommunity.microsoft.com/t5/Configuration-Manager-Blog/bg-p/ConfigurationManagerBlog

Join us there for announcements and best practice posts from the MDT team.

To get started:

  1. Create your account on the Microsoft TechCommunity
  2. Join the System Center Configuration Manager community
  3. Follow our new blog
  4. Add your contributions and comments to our discussion space

Note: This TechNet blog will remain in place for a period to allow access to historical blog posts but no further updates will be made here.

See you over on the TechCommunity.

-Yvette

Don’t forget the provider!!!

$
0
0

I have seen across the internet where folks have been frustrated, unable to remove a site system that used to perform some role in SCCM.  The prior role (DP, MP, etc.) was removed and now it only has two roles listed, "Component Server" and "Site System".  When attempting to delete it  you can't, because of the component server role still being listed.  Restarting the SMS_SITE_COMPONENT_MANAGER is a suggested step to take to get the component server role to clear and allow the deletion, but in some cases that won't work.  Why not?  Well.., the component server role is there for good reason..., there is still an active ConfigMgr component on the box.  Sure.. it no longer lists as a "site database server" or "management point" but it does have a function running on the machine.  There is one role that does not display through this area of the UI...., the provider!

To see what servers have the provider on them you need to navigate in the ConfigMgr Admin UI to AdministrationOverviewSite ConfigurationSites and bring up properties on the site that owns the site system.  If that is your hold up, then it is time to run your ConfigMgr setup and move your provider to a new location.


Runspace twospace, redspace bluespace…

$
0
0

This is the final of four posts on ways to accomplish parallel processing.  In the previous posts, we looked at using Jobs (or -AsJob), and WorkFlows.   Following the theme of those prior posts, we'll take a look at Runspaces, specifically under the microscope of looking at how the processes and threads are handled to see if it operates as we would think a true multithreaded application would work.

If you are looking for a basic how-to on runspaces. take a look at Boe Prox's article on TechNet for a good tutorial on how runspaces work.

I have to admit that before taking on this task to compare the different parallel processing methods of PowerShell, I had never heard of runspaces.  For me, it was the toughest parallel processing method to learn.  Don't let that dissuade you from taking on the challenge of learning this, the juice is definitely worth the squeeze.

Example Code

The script below is an example of a runspace that basically connects to all servers in my test lab and queries the security event logs for the latest 4000 event 4624s (successful logons).  The code to execute on the remote servers is in the scriptblock toward the bottom of the script and is passed as a scriptblock object parameter to the function higher in the script.

# RUNSPACE SAMPE

Function Process-Parallel($arr, $SB) 
{ 
    # CREATE THE RUNSPACE POOL
    $RunspacePool = [RunspaceFactory]::CreateRunspacePool(1,10) 
    
    # OPEN THE RUNSPACE POOL 
    $RunspacePool.Open()
 
    # CREATE THE RUNSPACE COLLECTION
    $RunspaceCollection = New-Object system.collections.arraylist 
    ForEach ($obj in $arr) 
    { 
        # CREATE A POWERSHELL OBJECT  
        $Powershell = [PowerShell]::Create()
 
        $Powershell.RunspacePool = $RunspacePool 
        $Powershell.AddScript($SB) | Out-Null 
        $Powershell.AddArgument($obj) | Out-Null 

        # CREATE THE RUNSPACE OBJECT
        $RS = New-Object -TypeName PSObject -Property @{
            Runspace = $PowerShell.BeginInvoke() 
            PowerShell = $PowerShell 
        } 
    
        $RunspaceCollection.Add($RS) | Out-Null 
    }

    # CREATE A RETURN ARRAY
    $Return = @() 

    While($RunspaceCollection) 
    {
        # GO THROUGH ALL THE RUNSPACES IN THE COLLECTION 
        ForEach($Runspace in $RunspaceCollection.ToArray())
        {
            # CHECK TO SEE IF RUNSPACE COMPLETED
            If($Runspace.RunSpace.IsCompleted -eq $true)
            {
                # ASSIGN THE RESULT TO $return
                $Return += $Runspace.Powershell.EndInvoke($Runspace.RunSpace) 
                $Runspace.Powershell.dispose() 
                $RunspaceCollection.Remove($Runspace)
            }
        }
    }
    Return $Return 
}

#  GET THE COMPUTERS TO BE CHECKED
$arr = get-adcomputer -filter * -server dc1.contoso.com:3268 

#  PUT TOGETHER SCRIPTBLOCK TO RUN
$SB = { 
    param($Computer) 
    $strCompName = $Computer.Name 
    $Count = (Get-Eventlog Security -ComputerName $Computer.Name -Newest 4000| `Where-Object {$_.EventID -eq '4624'}).count
    Return "$strCompName,$Count"
}

#  EXECUTE THE COMMAND
$Stats = Measure-Command {$OutTest = process-parallel $arr $SB} 

$OutTest 

$Stats

The Analysis

Using ProcMon from the SysInternals Tools Suite, I captured the execution of this script.  As you can see from the capture screenshot below, the runspace ran under a single PowerShell_ISE process, unlike the captures that we looked at with Jobs and WorkFlows (using InlineScript).  This gives runspaces an advantage since they do not consume excessive resources with multiple PowerShell environments.

 

In the filtered ProcMon capture below, you can see that the single PowerShell process ID spawns multiple threads to do the parallel processing, truly multi-threaded.

Now, the important part, the performance.  The runspace was blazing fast, executing the query in 37 seconds.  To give a frame of reference, execution times for  the exact same task with the different methods is listed below:

  • ForEach loop took 1 minute and 23 seconds
  •  Jobs took 1 minute and 20 seconds
  • WorkFlow took 1 minute and 17 seconds
  • RunSpace took 37 seconds

Just plain wow!!  I did have to tweak the Maximum number of runspaces  (2nd number in parenthesis below) to see what combination worked best for my environment.  My lab is just a normal desktop running 20 VMs, so it is pretty taxed at most times.  Your mileage may vary.

$RunspacePool = [RunspaceFactory]::CreateRunspacePool(1,10)

Now What?

The thing you have to consider with workflows is that there is a steep learning curve when compared to the other methods listed above.  In my experience, I tend to put that kind of effort into scripts that will return a dividend on the time investment.  It really comes down to your use case for the script.  If you need blazing fast performance and have the time and skillset to learn and embrace it, this is the only choice.

 

Happy Scripting!!

Windows 7/Office 2010 サポート終了を踏まえた Microsoft 365 への移行支援施策/キャンペーン【10/20 更新】

$
0
0

日本マイクロソフトでは、2020年1月14日に Windows 7、同年10月13日にOffice 2010のサポートを終了させていただきます。

買い替えや新規でのご購入を考えているなら、最新の Windows OS ※ と Office が使え、サポートの心配も不要の Microsoft 365 Business、および Office 365 Business Premium がオススメです。今なら、200 社限定で対象製品をご購入後、アンケートにお答えいただいた企業に、初回購入特典として最大で 1,000,000 円キャッシュバック (返金) いたします。

※ Office 365 Business Premium には含まれません。

 

キャンペーンの詳細及びお申込みはこちら

 

関連項目

 

 

 

Top Contributors Awards! C# Processing CSV files and many more!

$
0
0

Welcome back for another analysis of contributions to TechNet Wiki over the last week.

First up, the weekly leader board snapshot...

As always, here are the results of another weekly crawl over the updated articles feed.

 

Ninja Award Most Revisions Award
Who has made the most individual revisions

 

#1 George Chrysovaladis Grammatikos with 100 revisions.

 

#2 S.Sengupta with 41 revisions.

 

#3 Dave Rendón with 23 revisions.

 

Just behind the winners but also worth a mention are:

 

#4 get2pallav with 21 revisions.

 

#5 Andrei Stoica with 19 revisions.

 

#6 Arleta Wanat with 18 revisions.

 

#7 Jayendran arumugam with 16 revisions.

 

#8 Peter Geelen with 14 revisions.

 

#9 Bruno Lopes (MVP) with 13 revisions.

 

#10 Richard Mueller with 11 revisions.

 

 

Ninja Award Most Articles Updated Award
Who has updated the most articles

 

#1 get2pallav with 16 articles.

 

#2 George Chrysovaladis Grammatikos with 13 articles.

 

#3 Arleta Wanat with 12 articles.

 

Just behind the winners but also worth a mention are:

 

#4 Peter Geelen with 8 articles.

 

#5 Dave Rendón with 8 articles.

 

#6 RajeeshMenoth with 7 articles.

 

#7 Bruno Lopes (MVP) with 7 articles.

 

#8 Somdip Dey - MSP Alumnus with 3 articles.

 

#9 Jayendran arumugam with 3 articles.

 

#10 Richard Mueller with 2 articles.

 

 

Ninja Award Most Updated Article Award
Largest amount of updated content in a single article

 

The article to have the most change this week was User Page: Kamlesh Kumar, by Kamlesh Koomar

This week's reviser was Kamlesh Koomar

 

 

Ninja Award Longest Article Award
Biggest article updated this week

 

This week's largest document to get some attention is C# Processing CSV files Part 1, by Kareninstructor

This week's revisers were get2pallav & Kareninstructor

 

 

Ninja Award Most Revised Article Award
Article with the most revisions in a week

 

This week's most fiddled with article is Windows 10:Your phone app, by S.Sengupta. It was revised 24 times last week.

This week's reviser was S.Sengupta

 

 

Ninja Award Most Popular Article Award
Collaboration is the name of the game!

 

The article to be updated by the most people this week is Azure: Daily Reports using Logic Apps, by Jayendran arumugam

This week's revisers were Jayendran arumugam, Dave Rendón & George Chrysovaladis Grammatikos

 

 

Ninja Award Ninja Edit Award
A ninja needs lightning fast reactions!

 

Below is a list of this week's fastest ninja edits. That's an edit to an article after another person

 

Ninja Award Winner Summary
Let's celebrate our winners!

 

Below are a few statistics on this week's award winners.

Most Revisions Award Winner
The reviser is the winner of this category.

George Chrysovaladis Grammatikos

George Chrysovaladis Grammatikos has won 26 previous Top Contributor Awards. Most recent five shown below:

George Chrysovaladis Grammatikos has not yet had any interviews, featured articles or TechNet Guru medals (see below)

George Chrysovaladis Grammatikos's profile page

Most Articles Award Winner
The reviser is the winner of this category.

get2pallav

get2pallav has won 5 previous Top Contributor Awards:

get2pallav has TechNet Guru medals, for the following articles:

get2pallav has not yet had any interviews or featured articles (see below)

get2pallav's profile page

Most Updated Article Award Winner
The author is the winner, as it is their article that has had the changes.

Kamlesh Koomar

[Kamlesh Kumar] has been interviewed on TechNet Wiki!

[Kamlesh Kumar] has won 32 previous Top Contributor Awards. Most recent five shown below:

[Kamlesh Kumar] has TechNet Guru medals, for the following articles:

[Kamlesh Kumar] has not yet had any featured articles (see below)

[Kamlesh Kumar]'s profile page

Longest Article Award Winner
The author is the winner, as it is their article that is so long!

Kareninstructor

Kareninstructor has been interviewed on TechNet Wiki!

Kareninstructor has won 11 previous Top Contributor Awards. Most recent five shown below:

Kareninstructor has TechNet Guru medals, for the following articles:

Kareninstructor has not yet had any featured articles (see below)

Kareninstructor's profile page

Most Revised Article Winner
The author is the winner, as it is their article that has ben changed the most

S.Sengupta

S.Sengupta has won 9 previous Top Contributor Awards. Most recent five shown below:

S.Sengupta has not yet had any interviews, featured articles or TechNet Guru medals (see below)

S.Sengupta's profile page

Most Popular Article Winner
The author is the winner, as it is their article that has had the most attention.

Jayendran arumugam

This is the first Top Contributors award for Jayendran arumugam on TechNet Wiki! Congratulations Jayendran arumugam!

Jayendran arumugam has not yet had any interviews, featured articles or TechNet Guru medals (see below)

Jayendran arumugam's profile page

Ninja Edit Award Winner
The author is the reviser, for it is their hand that is quickest!

George Chrysovaladis Grammatikos

George Chrysovaladis Grammatikos is mentioned above.

 

 Says: Another great week from all in our community! Thank you all for so much great literature for us to read this week!

Please keep reading and contributing, because Sharing is caring..!!

 

Best regards,

 

[Power BI] DAX入門 (3) 相対日付 (Relative date) の実装 -地震速報の可視化-

$
0
0

この記事は、2016 年 7 月 25 日 に Data Platform Tech Sales Team Blog にて公開された内容です。

 

Microsoft Japan Data Platform Tech Sales Team

土井

DAX 入門 第 3 回目では、前回の応用として、相対日付の実装について触れます。

今回は 地震速報 データを使って、今日何時に地震が起きたか? 昨日起きた地震の最大震度は? 直近一週間何件地震があったか?といった形で相対日付で可視化するレポートを作ってみます。

作成するレポートは以下のようなイメージです。スマホで閲覧されている場合は こちらのリンク を参照ください

 

■データの取得

まず、前回の記事で作成したカレンダーテーブルを使うので こちら からダウンロードください。

pbix ファイルを開いて、”データを取得” メニューから “Web” を選択します。

image

 

URL に http://typhoon.yahoo.co.jp/weather/jp/earthquake/list/ を入力し、OK をクリックします。 (データ出典:Yahoo! Japan 天気・災害)

image

 

ナビゲーター画面では “Table 0” のチェックボックスを選択し、”編集”をクリックします。

image

 

■データの加工

取得したデータを分析しやすい形にするため、加工をしていきます。

まず、“発生時刻” 列を選択した状態で、”変換” メニューの ”値の置換” をクリックし、”ごろ” を削除します。

image image

 

“ホーム” メニューから ”データ型” を選択し、”日付/時刻” に設定します。これにより、日付・時刻に関する各種 DAX 関数が利用可能になります。

image

 

“列の追加” メニューから”日付”->“日付のみ” を選択します。

image

 

同様に “時刻” を追加します

image

 

次に “震源地” 列を地図上で可視化できるように加工していきます。

実際には緯度・経度を基に地図上にプロットすべきですが、ここではあくまでサンプルのため、都道府県名でプロットするよう加工していきます。

“震源地” 列をクリックして、”変換” メニューから “値の置換” をクリックします。

image

検索する値 = 県

置換後 = 県,

とし、OK をクリックします。

image

 

さらに、”列の分割” –> “区切り記号による分割” を選択し、

image

 

コンマで列を区切ります

image

 

震源地.2 列は不要なので、削除します。

image

 

次に、震源地.1 列を選択した状態で、”列の追加” メニューから “条件列” を選択します。

image

 

下記のように 1 都 1 道 2 府を例外処理します。また、都道府県名を含まない震源地については、今回は “その他” として処理します。

image

 

“震源地” 列が追加されました。 “震源地.1” 列は不要なので、削除します。

image

 

ここまでの加工のステップは全て “適用したステップ” として記録されています。プロパティから、クエリの名前を ”地震速報” と変更し、”ホーム” メニューから ”閉じて適用” をクリックします。

image image

 

カレンダーテーブルの ”日付” 列と地震速報テーブルの ”Date” 列のリレーションを張ります。

image

 

■相対日付列の作成

さて、前置きが長くなりましたが、ようやく本題に取り掛かります。

DATEDIFF 関数 を使ってふたつの日付型列から差を取得することができます。

DATEDIFF(<start_date>, <end_date>, <interval>)

※ interval には年、四半期、月、週、日、時、分、秒 のいずれかの単位を指定できます。

 

今回は下記のように、TODAY関数を使って本日から何日前か、を計算します。

DATEDIFF('カレンダー'[日付],TODAY(),DAY)

これと、SWITCH 関数や IF 関数を使ってカレンダーテーブルに対して列を追加していきます。たとえば、

相対日付 = SWITCH(DATEDIFF('カレンダー'[日付],TODAY(),DAY),0,"本日",1,"昨日",2,"おととい","3日以前")

あるいは

一週間以内 = IF(DATEDIFF('カレンダー'[日付],TODAY(),DAY)<=7,"TRUE","FALSE")

といった列を作成可能です。

 

また、前回の記事 で作成した週番号列を使って、相対週の算出もできます。

相対週 = SWITCH(IF('カレンダー'[年]-YEAR(TODAY())=0,WEEKNUM(TODAY(),21)-'カレンダー'[週番号],-1),0,"今週",1,"先週",2,"先々週","3週間以前")

 

これにより、冒頭のレポートのような、相対日付でのスライサーを配置することが可能になります。

image

 

■更新日時列の作成

今回のように、定期的にデータソースが更新される場合、更新日時をレポートに表示したいといった要件があるかと思います。

Power BI Desktop で現在の時刻を取得する方法はいくつかありますが、今回は DAX で取得する例をご紹介します。

“ホーム” メニューの “データの入力” をクリックします。

image

“テーブルの作成” 画面で、1 行 1 列目に適当な値を入れます。下記の例では “1” を入力しています。

テーブルの名称を ”更新日時” とし、”読み込み” をクリックします。

image

テーブルが作成されました。 “列1” 自体は不要なので、”レポートビューの非表示” で隠してしまいましょう。

image

 

“モデリング” メニューから “新しい列” をクリックし、以下のふたつの列を追加します。

image

更新日時 (UTC) = NOW()

 

更新日時 (UTC+9) = NOW()+9/24

NOW 関数 は実行環境のロケールにおける現在時刻を返します。 Power BI Desktop を日本語環境でお使いの場合は時差を意識する必要はありませんが、

クラウド (Power BI Service) にレポートを発行する場合、Power BI Service 内では UTC で時刻を取得する動きとなります。そのため、日本時間に合わせるために上記のような列を作成する必要があります。

 

これにより、冒頭のレポートのように、更新日時を表示することが可能になります。

image

 

■まとめ

記事がかなり長くなってしまったので、レポートの作成については端折ります。皆様のセンスで、自由にレポートを作成いただければと思います。

冒頭で埋め込んだサンプルコンテンツは こちら からダウンロード頂けますので、もしよろしければご活用ください。
 

[Power BI] DAX入門 (4) 動的なランキング計算 –RANKX 関数の活用-

$
0
0

この記事は、2016 年 8 月 24 日 に Data Platform Tech Sales Team Blog にて公開された内容です。

 

Microsoft Japan Data Platform Tech Sales Team

土井

DAX 入門 第 4 回目では、データ集計においてよく使われるランキング計算 (ランク関数) について触れていきます。

DAX では RANKX 関数や TOPN 関数を使ってランキング計算が可能になっています。今回は RANKX 関数について具体的な使用方法をご紹介していきます。

■サンプルデータのインポート

本記事では こちら の Excel ファイルをデータソースとして用います。(Power BI 自習書サンプルスクリプト として使用されている NorthWindJ データベースの一部となります。)

Power BI Desktop を起動して、上記の Excel ファイルを指定して商品テーブルと売上テーブルを取り込みます。

image

 

■メジャーの作成

モデリング メニューから、新しいメジャー をクリックします。

image

まず、売上金額を単純に集計するためのメジャー [売上計] を作成します。

売上計 = SUM('売上'[売上])

 

つぎに、売上が大きい順に商品ランキングをつけるために、メジャー [商品ランク] を作成します。RANKX の引数の詳細については リファレンス を参照ください。

商品ランク = RANKX(ALL('商品'),[売上計],,DESC)

 

これにより、下記のようなレポートをつくることができます。

image

 

■動的なランキング表示

たとえばさきほどのレポートで、商品区分名でフィルタリングをした場合、商品ランクは商品テーブル全体の中で何位か、を示します。

image

絞り込んだ商品区分の中でのランキングを表示したい場合、つまり、フィルター条件に基づいてランキング判定をしたい場合はさきほど作成したメジャーにおいて、 ALL 関数ではなく、 ALLSELECTED 関数を使用します。

商品ランク = RANKX(ALLSELECTED('商品'),[売上計],,DESC)

 

これにより、下記のようなレポートを作成できます。

image

 

フィルター機能を使って、下記のように トップ 10 など、任意の数字に絞り込むこともできます。

image

 

■まとめ

今回は RANKX 関数を使って、ランキング計算をする例を紹介いたしました。作成した Power BI Desktop ファイルは こちら からダウンロードできます。

ダウンロードいただいた、ranksample.pbit を開くと、下記プロンプトが表示されますので、冒頭でダウンロードした Excel ファイル が置いてあるフォルダパス (例えば、c:tmp など) を入力して読み込みボタンを押してください。

※フォルダパスの末尾に が必要なのでご注意ください

image
 

Viewing all 36188 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>