WEBVTT

00:00.450 --> 00:05.910
So we finally arrived at the moment where we actually start working with my as well.

00:06.030 --> 00:10.830
And by start working with I mean we're just going to install it and make sure it's running correctly

00:11.130 --> 00:12.570
on our cloud nine instance.

00:12.570 --> 00:14.100
But still it's something.

00:14.610 --> 00:20.720
So before we dive into that I just want to show you a post on the Cloud Nine community.

00:20.880 --> 00:27.930
This is written by one of the employees at cloud 9 and he's explaining how to use my Q Well inside of

00:28.050 --> 00:36.060
cloud 9 instead of a workspace and basically what it talks about is that they've created Clubine really

00:36.060 --> 00:40.920
quick and easy way to get my as well running in one of your workspaces.

00:40.950 --> 00:45.110
It's much much easier than what you would need to do to install it on your own.

00:45.150 --> 00:46.770
They have a nice little shortcut.

00:47.130 --> 00:49.410
There are three commands that we'll talk about.

00:49.440 --> 00:54.870
There are the three that are here basically start stop and Seelye.

00:55.380 --> 01:01.350
But before we go any further I just want to point out that these are not General Myers commands that

01:01.350 --> 01:03.420
you can run on any machine anywhere.

01:03.450 --> 01:05.540
These are actually cloud nine specific.

01:05.640 --> 01:12.150
So the upside of this is that they've made it really really easy almost too easy to get going with my

01:12.150 --> 01:16.060
ask you Will you just run these commands and you're there.

01:16.200 --> 01:17.520
It's kind of magical.

01:17.520 --> 01:24.300
The slight downside of that is that it doesn't work on every single machine and it is quite specific.

01:24.300 --> 01:29.970
So when you do install on a Mac or on a PC you always just have to relearn a new command to do basically

01:29.970 --> 01:30.880
the same thing.

01:31.230 --> 01:35.430
But for now since we're in cloud nine we get to appreciate how easy it is.

01:35.430 --> 01:43.080
So the first command is MY as well dash CTO space start and you'll notice that the three commands we're

01:43.080 --> 01:44.040
going to take a look at.

01:44.250 --> 01:45.390
All start with this.

01:45.410 --> 01:51.730
My Eskew Dasch CTO and I believe it stands for command line tool CTO.

01:51.750 --> 01:54.910
It's just the abbreviation that cloud 9 came up with.

01:55.350 --> 02:01.920
So this first one if we look at their documentation tells us it starts as well and it will create an

02:01.920 --> 02:02.930
empty database.

02:03.060 --> 02:04.450
The first time you started.

02:04.650 --> 02:06.140
So let's give it a shot.

02:06.270 --> 02:09.040
You might notice that I cleared out everything in this directory.

02:09.150 --> 02:11.530
He got rid of those two starter files.

02:11.550 --> 02:12.370
You don't have to do that.

02:12.390 --> 02:14.310
But I just wanted to get rid of clutter.

02:14.850 --> 02:16.470
So we're going to ride my ass.

02:16.480 --> 02:24.020
Q Well dash CTO space start you can see it's hard at work installing my s.

02:24.020 --> 02:27.460
Q Well it's starting up a server.

02:27.650 --> 02:29.450
It's doing a few other things.

02:29.450 --> 02:31.240
I don't need to worry too much about that.

02:31.250 --> 02:36.380
It tells us a root user is my account name database name is C9.

02:36.430 --> 02:38.220
It created a database for us.

02:38.240 --> 02:43.520
Again we'll dive more into this in the next section when we actually start talking about databases and

02:43.910 --> 02:47.190
how you create them and to work with tables and write sequel.

02:47.210 --> 02:51.090
For now all that we really care about is that something happened.

02:51.430 --> 02:53.090
Where does it get.

02:53.360 --> 03:00.030
So the next command is the same thing as to help Dasch CTO space this time.

03:00.350 --> 03:02.820
And that stands for command line interface.

03:03.050 --> 03:07.900
And what this will do is it will startup see my s Cuil interactive show.

03:08.090 --> 03:12.890
And if you've worked with any database before usually there is an interactive shell that goes along

03:12.890 --> 03:13.600
with it.

03:13.820 --> 03:20.000
Or if you've worked with things like Ruby or Python or Noad there are usually terminal or command line

03:20.000 --> 03:22.360
based interactive environments.

03:22.400 --> 03:28.160
If this is all new to you I think it's easiest to understand it just by using it and taking a look at

03:28.160 --> 03:28.400
it.

03:28.400 --> 03:37.440
So now let's try this again this time my as well dash CTO space CLID and we hit enter.

03:38.090 --> 03:40.000
So now we have a bunch of new text.

03:40.010 --> 03:48.080
Welcome to my as well monitor commands and with semi-colon and we'll come back to that in just a second.

03:48.470 --> 03:50.560
Tells us are my sequel my s.

03:50.560 --> 03:58.220
Q Well connection server version copyright gives us a little copyright notice here and now we're inside

03:58.220 --> 04:03.500
of what's known as the my s q all interactive show or the monitor.

04:03.680 --> 04:07.430
So this is where we can go to actually type commands.

04:07.580 --> 04:13.370
So if you think back to the telephone book example this is where we would go and say things like find

04:13.370 --> 04:20.450
me all users in our database who have a first name that is three characters long or find we all users

04:20.450 --> 04:23.110
in our database who are 18 years or older.

04:23.390 --> 04:28.010
So this is where we can go to type code to interact with an Access database.

04:28.280 --> 04:33.110
But it's also where we can go and type code that works more on the matter of.

04:33.260 --> 04:39.740
You can think of it as doing things around permissions creating entirely new databases transferring

04:39.740 --> 04:42.090
data from one database to another.

04:42.110 --> 04:46.740
There's a whole bunch of things we do in this show and we'll be working with this quite a bit.

04:46.760 --> 04:49.120
So for now we're not going to do that.

04:49.130 --> 04:54.050
We're going to wait till the next section all that we're going to see right now is that you can quit

04:54.050 --> 04:55.220
this.

04:55.370 --> 04:58.310
There are quite a few ways of quitting the show.

04:58.760 --> 05:03.180
We can use exit notices semi-colon quit.

05:03.440 --> 05:07.320
Also notice the semi-colon we can use backslash.

05:07.320 --> 05:12.230
Q I always mix up forward and back slash but this slash pointing down.

05:12.230 --> 05:13.610
Q Or what.

05:13.610 --> 05:18.870
I usually use Control C so whatever works best for you.

05:18.950 --> 05:23.390
I think there are actually a couple more different ways of quitting depending on the platform you're

05:23.390 --> 05:24.240
using.

05:24.290 --> 05:29.290
But for me I usually use Control-C but just to illustrate that I'll do two of them.

05:29.290 --> 05:38.890
So let's do quit and go on we get a nice message by Seems that will said we can restart the Selye but

05:38.900 --> 05:42.300
either retyping that whole thing or just hitting the up arrow.

05:42.680 --> 05:45.140
So I'm going to do that now and hit enter.

05:45.140 --> 05:46.710
We get this exact same message.

05:46.730 --> 05:48.080
You'll see it every time.

05:48.290 --> 05:52.410
This time I'm going to use the Control see just have to trust me.

05:52.420 --> 05:57.920
Did it actually you won't because you can see it here Control C this time it says aborted.

05:58.190 --> 06:00.850
So it turns out there actually is a little bit of a difference.

06:00.860 --> 06:08.980
If you notice or appear it said by it kind of was expecting to quit because I use the Quit command.

06:09.020 --> 06:11.370
And here I just ended the process.

06:11.750 --> 06:13.860
Which is why it says aborted.

06:13.970 --> 06:20.200
So technically there's a difference but I just use Control-C because you don't have to type anything.

06:20.270 --> 06:21.060
It's much easier.

06:21.060 --> 06:23.760
You don't have to hit the enter key you don't need a semi-colon.

06:24.170 --> 06:25.280
Really whatever you prefer.

06:25.280 --> 06:29.240
Some people like to be more explicit and use quit or exit.

06:29.710 --> 06:30.290
OK.

06:31.670 --> 06:35.530
So the last command that we're going to take a look at is my ask.

06:35.580 --> 06:43.200
Well dash see T.L. space stop and you're really really rarely going to use this one but this one will

06:43.200 --> 06:47.080
do is stop the minuscule process completely.

06:47.360 --> 06:49.190
So I understand what that means.

06:49.230 --> 06:55.650
It helps to understand what happened when we typed this first command here that started everything.

06:55.650 --> 06:59.310
So what that did is that it started up a new instance of my s.

06:59.310 --> 07:07.660
Q Well then that's running constantly in the background at all times until we stop it when we use this

07:07.660 --> 07:11.690
second command my s to l CTO CLID.

07:11.910 --> 07:19.230
I know it's a lot of abbreviations here but when we use that CLID command it is connecting to the instance

07:19.230 --> 07:23.320
of my s l that was started up from the first command.

07:23.880 --> 07:32.760
So just to reiterate this Seelye when we do this and started up it is connecting to my s l connection

07:32.760 --> 07:40.950
that we started up earlier so I'll exit and if we wanted to we can stop that background process we can

07:40.950 --> 07:43.380
stop my rescue from running completely.

07:43.410 --> 07:45.660
So we're not just stopping the Seelye.

07:45.690 --> 07:46.910
This has already stopped here.

07:47.020 --> 07:57.940
We can stop everything related to my ask while using my q dash CTO stop and it just tells us stopping

07:58.000 --> 08:00.650
my escort database server blah blah blah.

08:01.160 --> 08:02.550
OK so three command.

08:02.710 --> 08:10.030
Realistically the way that this whole work is that well started up and we're going to leave it running

08:10.570 --> 08:16.020
for basically the entire course and we're going to start and stop the Selye all the time.

08:16.390 --> 08:21.740
Pretty much every other video will be starting up the Selye typing some code quitting.

08:21.880 --> 08:25.710
So you should get used to that but you don't really need to worry about stopping it all that often.

08:25.880 --> 08:31.720
OK so next up we just have a quick little exploratory activity where you'll be able to type some new

08:31.720 --> 08:34.730
commands into this reply and see what happens.
