2.0 Databases.pptx - Databases Sql language SQL SQL is a...

This preview shows page 1 - 9 out of 24 pages.

DatabasesSql language
SQLSQL is a standard language for storing, manipulating and retrieving data in databases.We will learn how to use sql in Mysql in database system.
What is SQL?SQL stands for Structured Query LanguageSQL lets you access and manipulate databases
What Can SQL do?SQL can execute queries against a databaseSQL can retrieve data from a databaseSQL can insert records in a databaseSQL can update records in a databaseSQL can delete records from a databaseSQL can create new databasesSQL can create new tables in a databaseSQL can create stored procedures in a databaseSQL can create views in a databaseSQL can set permissions on tables, procedures, and views
RDBMSRDBMS stands for Relational Database Management System.RDBMS is the basis for SQL, and for all modern database systemssuch as MS SQL Server, IBM DB2, Oracle, MySQL, and MicrosoftAccess.The data in RDBMS is stored in database objects called tables. A tableis a collection of related data entries and it consists of columns androws.
SQL DatabaseSQL CREATE DATABASESyntaxCREATE DATABASEdatabasename;ExampleCREATE DATABASE zalego;
The SQL CREATE TABLE StatementThe CREATE TABLE statement is used to create a new table in adatabase.SyntaxCREATE TABLEtable_name(column1 datatype,column2 datatype,column3 datatype,....);The column parameters specify the names of the columns of thetable.The datatype parameter specifies the type of data the column canhold (e.g. varchar, integer, date, etc.).
SQL CREATE TABLE ExampleExampleCREATE TABLE students (StudentID int,LastName varchar(255),FirstName varchar(255),Address varchar(255),City varchar(255));

Upload your study docs or become a

Course Hero member to access this document

Upload your study docs or become a

Course Hero member to access this document

End of preview. Want to read all 24 pages?

Upload your study docs or become a

Course Hero member to access this document

Term
Summer
Professor
d john
Tags

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture