Would you like to inspect the original subtitles? These are the user uploaded subtitles that are being translated:
1
00:00:05,190 --> 00:00:05,760
In this lesson.
2
00:00:05,760 --> 00:00:07,800
We're going to continue from the previous lesson.
3
00:00:07,800 --> 00:00:11,250
And in the previous lesson we created a new field called Weekday.
4
00:00:11,280 --> 00:00:15,390
Now we had this number from one through to seven, and we've summed up the sales for that.
5
00:00:15,420 --> 00:00:20,490
Well, one of the questions we were asking was how do we know if this is a monday or Tuesday or Wednesday?
6
00:00:20,520 --> 00:00:26,280
Now, might be far better to actually have the name of the actual day in there rather than just a number.
7
00:00:26,280 --> 00:00:28,470
And really the same applies for your month as well.
8
00:00:28,470 --> 00:00:32,479
We currently got a month number, but you might want to have the month name there.
9
00:00:32,490 --> 00:00:35,700
So in this lesson we're going to be looking at how we can create those names.
10
00:00:35,700 --> 00:00:40,050
So we're going to go back to our data and move across a bit.
11
00:00:40,050 --> 00:00:44,160
So we've created a few new fields now a year, month, day, and we've got a weekday.
12
00:00:44,640 --> 00:00:48,750
What we're going to do is we're now going to create a new column and we're going to say that this is
13
00:00:48,750 --> 00:00:51,330
going to be all week, day nine.
14
00:00:52,320 --> 00:00:55,590
We'll just give that a capital letter we then name.
15
00:00:55,590 --> 00:00:58,560
Now we are going to use a different function here.
16
00:00:58,560 --> 00:01:01,290
So we're going to use a function called equals format.
17
00:01:01,620 --> 00:01:06,690
Now, if you're familiar with your Excel functions, you might know a function called equals text.
18
00:01:06,690 --> 00:01:09,930
Equals text would actually be the way that we would do this in Excel.
19
00:01:09,930 --> 00:01:13,080
But as I say, index, we're going to be using equals format.
20
00:01:13,080 --> 00:01:18,930
So I'm going to start start typing that EFO and you can see that we get the format function.
21
00:01:18,930 --> 00:01:21,990
So let's select that and again we get our parentheses.
22
00:01:22,140 --> 00:01:24,900
However, you'll see that it does have a couple of options.
23
00:01:24,900 --> 00:01:27,960
So it's asking what is the value, what is the format?
24
00:01:27,960 --> 00:01:31,740
And then the column name is in your square brackets.
25
00:01:31,740 --> 00:01:33,480
And what that means is it's optional.
26
00:01:33,480 --> 00:01:38,220
So really this is saying when when you're setting your format, you can have the column names that can
27
00:01:38,220 --> 00:01:38,870
be used.
28
00:01:38,880 --> 00:01:40,200
I'm not going to be using them.
29
00:01:40,200 --> 00:01:41,880
It is an optional extra.
30
00:01:41,880 --> 00:01:44,040
So the first part is what are we formatting?
31
00:01:44,040 --> 00:01:46,770
So in this case we still formatting our sales date.
32
00:01:46,770 --> 00:01:48,900
So again, I'm going to use my left square bracket.
33
00:01:48,900 --> 00:01:55,080
I'm going to go down to my sales date and we're going to select that and you'll see that we do get some
34
00:01:55,080 --> 00:01:56,100
additional options here.
35
00:01:56,100 --> 00:01:56,850
We don't need that.
36
00:01:56,850 --> 00:01:58,350
We just need the cells that field.
37
00:01:58,350 --> 00:02:02,370
So I'm just going to press comma, and that means now we move on to what format.
38
00:02:02,370 --> 00:02:06,900
And you can see at the top it's turned blue, which is telling me I've now moved across to that argument.
39
00:02:07,170 --> 00:02:11,940
Now, just like in Excel, we're going to use our quotations, so I'm going to select my quotations
40
00:02:11,940 --> 00:02:12,450
here.
41
00:02:12,450 --> 00:02:17,280
So just put our quotations in and we're going to tell it how to format the weekday name.
42
00:02:17,280 --> 00:02:22,680
Now, if I use four D's and it doesn't really matter if I use Capital DS or small DS, but if I put
43
00:02:22,680 --> 00:02:27,390
four D's in here, you're going to see that I get the full name of the actual weekday.
44
00:02:27,540 --> 00:02:29,130
So let's show an example of that.
45
00:02:29,130 --> 00:02:31,590
Close my quotations, close my parentheses.
46
00:02:31,830 --> 00:02:34,860
So just to review, we've got equals format.
47
00:02:34,860 --> 00:02:39,570
We're saying we're formatting the sales date and we've got four D's in there that's telling me that
48
00:02:39,570 --> 00:02:41,640
I'm going to get the full name of that.
49
00:02:41,970 --> 00:02:47,070
So let's press enter and you can see we've got the weekday name now, it's Wednesday, Monday, Wednesday.
50
00:02:47,070 --> 00:02:52,530
So this is far more useful when we're trying to understand what is the actual weekday name.
51
00:02:53,250 --> 00:02:57,540
If I was to use three DS, for example, let's just remove one of those D's.
52
00:02:57,540 --> 00:02:59,700
So we just got three D's center.
53
00:02:59,820 --> 00:03:02,160
You'll see that I got the shortened version of this.
54
00:03:02,160 --> 00:03:04,560
I just get the first three characters.
55
00:03:04,680 --> 00:03:07,980
So in this case, I'm actually going to keep it as the first three characters.
56
00:03:08,430 --> 00:03:11,880
So we're going to go in and we're going to actually go back to our report.
57
00:03:12,300 --> 00:03:17,550
Now we're going to have the weekday name here, and while we've got the weekday field at the moment,
58
00:03:17,550 --> 00:03:21,180
let's drop the weekday name in there just to add it in.
59
00:03:21,290 --> 00:03:23,130
Let's just grab it in there.
60
00:03:23,950 --> 00:03:29,980
So now you'll see that weekday one is actually Sunday, two is a monday, Tuesday, Wednesday, Thursday,
61
00:03:29,980 --> 00:03:31,120
Friday, Saturday.
62
00:03:31,600 --> 00:03:35,870
So there we've got now the actual report showing me my weekday name.
63
00:03:35,890 --> 00:03:40,570
However, if we were to remove our weekday field, let's just remove that out.
64
00:03:40,690 --> 00:03:42,340
You'll see that things suddenly changed.
65
00:03:42,670 --> 00:03:47,900
So you see that certainly in this weekday name now changes to Friday and Monday, Saturday, Sunday.
66
00:03:47,920 --> 00:03:50,510
It's actually lost its chronological order.
67
00:03:50,530 --> 00:03:56,430
And the reason for this is that the system does not know that this is actually a weekday name field.
68
00:03:56,440 --> 00:03:58,480
It's actually just looking at this text.
69
00:03:58,630 --> 00:04:02,140
Now, when we hit the weekday in here, let's just pop that back in again.
70
00:04:02,680 --> 00:04:04,930
That was being used to actually sort it.
71
00:04:04,960 --> 00:04:07,060
So when we sought our weekday.
72
00:04:08,080 --> 00:04:12,580
Let's just say from 1 to 7, then you'll see that this is in the correct order.
73
00:04:13,450 --> 00:04:14,830
Okay, So this is a bit of a challenge.
74
00:04:14,830 --> 00:04:20,860
If we're not using the weekday, how do we actually now get the weekday name to be in the correct chronological
75
00:04:20,860 --> 00:04:23,470
order and not in an alphabetical order?
76
00:04:23,770 --> 00:04:27,190
So again, we do get an option from Microsoft to help us with this.
77
00:04:27,220 --> 00:04:33,610
So when I click on my weekday name field and go to the column tools, you'll see something called sort
78
00:04:33,610 --> 00:04:34,540
by column.
79
00:04:34,720 --> 00:04:37,870
Now, this does give you other options that you can use sort by four.
80
00:04:37,870 --> 00:04:43,540
But one of the main reasons for this is to be able to sort your week names, your month names into the
81
00:04:43,540 --> 00:04:44,440
correct order.
82
00:04:44,830 --> 00:04:50,580
And what that means is I can actually say that we are sorting our week then name by week day.
83
00:04:50,620 --> 00:04:53,530
So it's telling which field to actually sorted by.
84
00:04:53,770 --> 00:04:58,040
So just to review that again, we've now got a weekday name selected.
85
00:04:58,060 --> 00:05:02,620
We've gone to sort by column and we're going to tell the system, we're going to sort this field by
86
00:05:02,620 --> 00:05:04,000
the week, day field.
87
00:05:04,660 --> 00:05:05,470
Select that.
88
00:05:05,920 --> 00:05:11,560
And you'll now see that the weekday name is now chronologically correct, because Sunday, Monday,
89
00:05:11,560 --> 00:05:13,630
Tuesday, Wednesday, Thursday and Friday.
90
00:05:14,050 --> 00:05:16,510
So that's how we actually do this.
91
00:05:17,320 --> 00:05:18,610
So that's all week then name.
92
00:05:18,610 --> 00:05:22,150
What I'm going to do is we're going to create a month name field as well.
93
00:05:22,150 --> 00:05:27,940
So I'm going to run through the set of processes that we've just done, just to show you another example
94
00:05:27,940 --> 00:05:28,570
of this.
95
00:05:28,600 --> 00:05:35,600
So let's go back into our data and let's create a new field and we're going to get a new column again.
96
00:05:35,620 --> 00:05:37,030
Please remember new column.
97
00:05:37,240 --> 00:05:41,020
And in this case, we're going to be calling this by month name.
98
00:05:41,140 --> 00:05:45,070
So we're going to say again, equals in this case, we're going to be using all format.
99
00:05:45,890 --> 00:05:47,720
So choose format.
100
00:05:47,720 --> 00:05:50,120
And again, my value is my sales date.
101
00:05:50,120 --> 00:05:53,180
That is what we're using format, this comma.
102
00:05:53,510 --> 00:05:55,190
Then it asked me what is my format?
103
00:05:55,190 --> 00:05:57,680
Now, in this case I'm working with a month name.
104
00:05:57,680 --> 00:06:03,620
So what I actually use is my quotations and if I use for EMS again, it doesn't matter if you actually
105
00:06:03,620 --> 00:06:04,490
use more.
106
00:06:04,790 --> 00:06:10,790
I could have for EMS this more use my quotations, close my parentheses and again, you probably guess
107
00:06:10,790 --> 00:06:16,370
this already, but when I press enter I get the full month name because I'm using for EMS.
108
00:06:16,640 --> 00:06:23,480
However, if I go back into this, delete one of the EMS press that I get the shortened version.
109
00:06:23,480 --> 00:06:28,790
So just remember with weekday name, we use these for the day, for month, we use EMS.
110
00:06:29,030 --> 00:06:30,050
Okay, So that's looking good.
111
00:06:30,050 --> 00:06:31,700
We've now got our month name.
112
00:06:31,700 --> 00:06:33,500
Let's go back into our report.
113
00:06:33,950 --> 00:06:35,630
Let's create a new table.
114
00:06:36,380 --> 00:06:39,890
And we're now going to use our own name in this.
115
00:06:40,340 --> 00:06:42,410
So let's drop my name in there.
116
00:06:43,040 --> 00:06:45,350
And we're going to now drop ourselves in there.
117
00:06:46,290 --> 00:06:51,630
And you can see straight away we do have a problem because the it is alphabetical in terms of the way
118
00:06:51,630 --> 00:06:52,980
that it is sorting this.
119
00:06:53,400 --> 00:06:57,860
So just like we did previously, we are going to use that sort by field.
120
00:06:57,870 --> 00:07:00,480
So we're going to choose our month name on it.
121
00:07:00,900 --> 00:07:06,120
Just remember to click on the field, name your column, Tools will open and we're using the sort by
122
00:07:06,120 --> 00:07:06,660
column.
123
00:07:06,660 --> 00:07:12,120
And in this case we're saying the month name is going to be sorted by the month number.
124
00:07:12,240 --> 00:07:15,380
So the month number, remember, is this field called month.
125
00:07:15,390 --> 00:07:17,040
So we're just going to select that.
126
00:07:17,250 --> 00:07:20,520
And now you'll see that that is chronologically correct.
127
00:07:21,420 --> 00:07:24,570
So again, just to review that, click on the month name.
128
00:07:24,840 --> 00:07:26,310
Go to your soap bar column.
129
00:07:26,490 --> 00:07:30,480
And then we're picking the month number as the soap bar.
130
00:07:30,990 --> 00:07:36,900
So I hope this makes sense and that you can see how we can use the soap bar to be able to get the correct
131
00:07:36,900 --> 00:07:39,870
order for our weekday names and for our month names.
132
00:07:39,900 --> 00:07:44,100
It's a little bit of a workaround, but once you've set this up, once in your daily model, you don't
133
00:07:44,100 --> 00:07:47,600
need to do it again and it will then always default.
134
00:07:47,610 --> 00:07:51,030
It doesn't matter if you're creating a graph or if you're creating a table.
135
00:07:51,120 --> 00:07:53,400
Actually, let's just show a quick example of that.
136
00:07:53,550 --> 00:07:57,300
So if I now created a graph, let's show a column graph.
137
00:07:57,750 --> 00:08:04,410
And because we've now got the month name in the right order, when I drop my month name into my axis,
138
00:08:04,410 --> 00:08:06,150
let's say ourselves in our Y.
139
00:08:06,600 --> 00:08:10,830
There you can see now that we've correctly got these in the correct order.
140
00:08:11,190 --> 00:08:12,080
So there we go.
141
00:08:12,090 --> 00:08:15,330
That's an example of how we use those fields.
142
00:08:15,360 --> 00:08:18,970
And the next lesson, we're going to be moving across to using a date master.
143
00:08:19,010 --> 00:08:23,280
One of the reasons for that that we're going to see is that as you start working with this, you can
144
00:08:23,280 --> 00:08:26,130
see that I'm starting to build up quite a number of fields.
145
00:08:26,340 --> 00:08:29,310
And this can take quite a bit of time when you're setting up your data model.
146
00:08:29,340 --> 00:08:34,080
So sometimes you might want to just set this up once and then import it into your system.
147
00:08:34,080 --> 00:08:35,900
But let's cover that in the next lesson.
148
00:08:35,909 --> 00:08:36,870
I will see you there.
14649
Can't find what you're looking for?
Get subtitles in any language from opensubtitles.com, and translate them here.