sql Flashcards
what is database?
database is a collection of data and a method for accessing and manipulating the data.
databases captures and stores the data so that we can use it.
different databases
there are many databases out there because there are different types of data
and every user every company uses data in a different way.
eg:ibm, oracle, my sql, micreosoft sql server,cassandra etc.
what is dbms
database management system is a software it is a program used to manage database .it receives instructions from somebody like us that wants somthing to do with the data or make changes in it.
what is rdbms
relational data base management system is a subest of database management system they are most useful and most common databases.sql , sql lite. oracle uses this kind od database management system .
sql
structured query language is a way to interact with database mangement system
query
query is a type of instruction. queries are the ways that we are goung to put our questions and to which we want answer from the database
what is heirarchial structure in sql
heirarchial structure has a parent and child node relationship .it has drawbacks and every child can only have one parent, and when you delete a parent node child node will be deleted. child node is directly connected to parent node
what is networking modal
networking modal expanded on to heirarchial modal and allows many to many relationships, child entites could have multiple parents
relational modal
it does’t have parent child relationships it organizes data in tables also called relations
crud
create , read , update ,delete these are the things done by sql.its also going to secure the data.
columns
column stores domain and constrains also called as attributes , for ex : this column has this attributes and the collection of columns is called a degree
rows
rows are also called as tuples . tuple is nothing but a singular row of data .
primary key
primary key uniquely identifies the data.
foreign key
foreign key is a key which references prmary key of a different table
oltp
online transaction process . data of tranmsactions on daily basis.these are the databases driving day to day transaction
olap
online analytical process
sql commands
dcl. dml , dql ,
–dcl stands for data control language.it grants and revokes access, ability to give certain access to certain dataset or revoke access to certain data.
==ddl : data definaton language ddl is used while setting up the data base . in ddl we can create ,alter , drop , rename,truncate , comment.
dql
data query language contains select statement and is one that drives your world
dml
data modificaton language , once we use ddl to define our database we are actually talking about the data
why postgres sql
we are using postgres sql and valentina db for the course . valentina db is an ui used to manage postgres . we are using postgres as it is widely used