Changes

Jump to: navigation, search

OPS345 Lab 4

701 bytes added, 01:41, 5 January 2022
Set up Nextcloud
{{Admon/tip|Don't be lazy|The only way to learn this stuff is to practice it. So practice it, don't skip steps. In fact: make up your own extra steps to give yourself more practice (a.k.a. experience). That's what employers pay for. Nobody in the industry will care what grades you got in school. They will care quite a bit about what you are able to do, and how willing and able you are to learn more.}}
* As a fundamental security principle: '''do the rest of the lab as a regular user, don't use root'''.
* To run the MariaDB client you need to know what to connect to. Find the FQDN ("endpoint") for ops345db in the web interface:
[[File:AWSDBFQDN.png|800px|border|center]]
* See also [https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_Troubleshooting.html Troubleshooting for Amazon RDS].
== Some basic SQL ==
 
You're going to learn some basic SQL commands to..........
 
Though the SQL console looks a little bit like the Linux commandline: they have almost nothing in common. In the SQL console you can write some MariaDB commands, but most of the time you write SQL statements. You can't execute any shell commands. SQL statements (queries) end with a semicolon, to make it clear that you're not trying to run a multi-line query.
 
Out of the box your ops345db has four databases, all of which are used internally by MariaDB. They are not used to store data for your applications:
<source>MariaDB [(none)]> show databases;
+--------------------+
| Database |
+--------------------+
| information_schema |
| innodb |
| mysql |
| performance_schema |
+--------------------+
4 rows in set (0.00 sec)
</source>
* Most mysql commands need to have a semicolon at the end.
* The mysql commandline is nothing like the linux shell. Have to use mysql (or plain SQL) commands.
* Out of the box show databases; shows 4 databses, all of which are used internally by mysql, they are not for you to store data.
* use mysql; show tables; select * from user; select user from user;

Navigation menu