Introducing
Your new presentation assistant.
Refine, enhance, and tailor your content, source relevant images, and edit visuals quicker than ever before.
Trending searches
SELECT FirstName, LastName
FROM Employees
WHERE City = "Reading"
CREATE USER 'daniel'@'localhost'
IDENTIFIED BY 'my_password';
We also use SQL to search for and retrieve specific data from the database.
We use this so we can then produce reports and perform other functions based on the data.
The Select command is used for this.
RBMSs are often designed to be accessed by many different users.
We use SQL to assign usernames, passwords & priviliges.
The two main commands for this are:
GRANT ALL ON *.*
TO daniel'@'localhost';
http://www.knowitallninja.com
UPDATE Employees
SET LastName = 'Thompson', City= 'Swindon'
WHERE EmpID = 1
The granting of privileges is important for security as it limits damage that can be caused by an individual user.
There are also SQL commands that are designed to ensure data integrity is maintained & to backup data.
These can be quite different between different RDBMSs though.
When you want to modify the data being stored in your database you will use:
INSERT INTO Employees (FirstName, LastName, Address, City, PostCode)
VALUES ('Michael', 'Cross', '21 Bodmin Road', 'Reading', 'RG4 6XZ');
DELETE FROM Employees
WHERE EmpID = 1;