You are on page 1of 2

Anthony Grullon

2/3/2015

We are going to cover MYSQL, SQL Server, and Microsoft SQL in class
At home we are going to cover
Open MYSQL 5.5. Enter hello for the password. Type exit to exit the program.
Use the snipping tool to take notes
Type hello as the password
Read everything that youre given on the screen
Type help
What is a database?
A database is a collection of raw and related data.
RAW: information was entered at random
When does data become information?
Data becomes information when it is processed
Data is unprocessed FACTS
There are two things you can do with a database
1.

You can put stuff in 2. You can take stuff out

Create database TOY;


Use TOYS;
Select ID from TOYS where targetage > 3;
Delete from catalog where production status = Revoked;
SQL is Structured Query Language

MYSQL is a version of SQL for free. Oracle SQL is another type of SQL. Some items are
different , some items are the same. We are taught Oracle SQL in the textbook. SQL was decided
to be user-friendly. Each line is called a Statement. Every statement begin with an action word.
Every statement ends with a semi-colon. When statements are created, they are divided into three
broad categories.
The DDL. The Data Definition Language. Refers to when we have relationships among
different pieces of data. Where we define the database. This is where we created the table and
column types. Where we keep the indexes.
The DML. The Data Manipulation Language. This one controls the adding and the removing
of records. A query is a question. This is where query stuff. Also about joining tables. We verify
the data integrity.
The DCL. The Data Control Language. Where we control the access levels and security
priveliges. You can set it up for fields. Can be set up on a per user basis or it can be set up for a
group. Can be set up on a per HOST basis.
Create DATABASE library; Query OK
SHOW DATABASES;
USE libraries;
MYSQL > = the mysql prompt
Type SHOW TABLES;
USE action leads you into another level.
INSERT INTO members(members_id, fname, lname, tel, email) VALUES
(NULL, John, Doe, 1234567, jdoe@somewhere.com)
NEXT MONTH MARCH 17th We will not be in class

You might also like