ullaskunder3 / pl-sql-prac

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

in RDBMS data is stored in multiple tables each table can have a set of rows and colums

  • tables related to their DB can have relations

SQL command

  • ddl: create , drop, alter, trunicate
  • dml: insert, update, delete, merge
  • dcl: grant, revoke
  • tcl: commit, rollback, savepoint
  • dql: select

data types varchar, int, date, float, boolean

step 1: CREATE TABLE student ();

Real world example REST API with MariaDB sql

This API allows you to perform CRUD operations (Create, Read, Update, Delete) on user records stored in a MariaDB database.

project link User REST API

With MariaDb

sudo systemctl enable mariadb
sudo systemctl start mariadb
sudo systemctl status mariadb
sudo systemctl stop mariadb
mysql -u root -p
show databases;

With postres SQL

sudo service postgresql restart
sudo service postgresql start
sudo service postgresql stop
sudo -u postgres psql

-- List all databases via \l (or \list), or \l+ for more details

postgres=# \l

About


Languages

Language:PLpgSQL 100.0%