SQL1
SQL1
No sQL
Oracl
wuluee you ty to&He
data u yat, alway.LObk
strcyddata
....
eguivalut to exul
ouy strutud dat
No SL This systt
0cLOmdat ustruetud data'
bestd
Tudgratiou
DOMS
Palabase Database is e colleetiou
data u............
ferat hat
lhatca
acce ssed
................ (Digital)
ybdicatiou
DB.s.Calld DBNS
Rualiouel NouReadioual
(NO SQL)
tablus. data wot stoud
tabls
Postau sql
Alatoual D6 HS
is SL ?
******e.eees*****.
&tueuud
******essen.2
(oset. hat
tuiu idiijis eacl
la wigul id)
Thuseis. Aouc be
NOT vul
tabethat
Tue Cobe wulliBle
eeeeaeeeeeeoeeteeeeees eeseseeeseeeseeeeeeeeeee
****e*.te*aesre
Coustrins
.. ..... to.
kpeitylulu fer data iu a table
NOT NäLL
*.....e.....****** ***********
tounsauuehae
mll ¯ae
codant NOT: NULL
UNIUE al ....................... eeesete...
***.***.............
diljaut
tod iut
ut UNI QVE.
iditPRINARY KEY:
CREA TE TABLE teuss
id ivt wot wul
PRIMARY KEYid)
)
puueetatos Mat
wbuld dstrey lils
iuls blw talales
CREATE TABLE
custidit
FoREIGA! KEY (custid) lues
ustow(id)
-Dejaudt Bets
...
Saly.INTDEFAULT :2000.
L cRETE TABLEeus
idNT
Saay NT DE FAULT 2gb0o
INSERT INTO
VALUES (o1)
id Salay
NSEET
CHÊCK
CREATE TABLE
id INT PR| MARY KEY,
ciy VARCHAR (so),
age IN T,
......
CONSTRAINT ageheck
CHECKCoge>= 18. AND
city =belui")
CREATE TABLE. newTab (
CHECK
IN TCHECK (age > 18)
)
databal ’
tudut
hol no, Kame Marls.
"c Pu
' Bhuuila
10 2 -’"Bhia '93" A4" Muwai
(DD chtui 3s'e' Hba
eee.s
Dellu
foak 22 Dell
asteisL
600aeeseee4
meaus, o l : !
SE LECI * FROM studiut
Ly oeeeseeeeseesseeee.e..
eeese.eness.
we uae to watca
enseesseeneseseess.essses.s.. .............
Cuil 79
93
SELEC T DISIINT) FROM. Atudud
Puue wl uot be
Humbai
dellui
Repaotie
Whelause
Ly
...
To .deiedowe tonditious &oe.....eee.........s..e
clubbe .......
ut lykal )
>.)=, <,<=
Kogical ohualos.
uatos i 4ND, OR
eeeeeseseeeas.
NOT
ALL LI KE
ANY
Bitwise ßuatos............ss......
l ( twise OR)
Kogical ofuatensi
AND,
A
"***...** ......s****.******
BETNEEN&let
SELECT * CRoM&tudut
WAERE maty B£TWEEN 80 ANDg0: ...A...t.....I...........
WHERE ..........
SELECTFROYstudut
WHERE tily <oI NCpeli" Muabai").
marks studuts
ducoring
SELECI * FROM studt
ORDER &Y mats ESC
Dhhuw
Bhumika
Chtau 82
Fah 78
12
Bhon nauus a Top 3Studuta.
SELECT FROM ............ .. ..
104 96.
102 Shuike 13
Chdn
.................7.....
8
. .....
DOMS
4ggegat Puuctious
alulaliouua. tqvales.
Qnddetuaingu Ualul
ee&@eeesseseeneeeeeeee
Max ()
L SELECI wMax (mas)
oeeeeeeseeegee EROM.&tudud
coeui..
Cot nub
....
Btudut u
Coueut (naue)
Pune
Muuubai 2
Dlhi
DOMS
Malls studt
aity dusuud
LSELECTaitt ug.make)
FROM.studut
GqROUP BY -
ORDER AY aun (mees) DESC;
......
khow ustous
to Rah
*.****.***....use.*..**..,.
huttod.
DOMS
wodeEROH custo aueba
SELECT
G RoUP B
wod ................
tauinylause
Bimila to oHERE i.e.
Loe tonditouo.Ow
atplics ......
wat
....*.....
to
********a******...........
aitylhee.
SELECT cont( nawe)
fRo. tudut
GRoUP sYity
Geneal de.
SELE cT Coumna)
CROM tablenaMe
WHERE Condilou
GROUP Y coumA)
H4vING Condiion
ORDER 6Y Coluwmns 4SC ;
Table uis.
WHERE coudtiou
u PDATE btudant
SEIgade
wHERE gladu
hasQ.
eoeeeeeeses
ON DELÉ TE CASCMDE
DN UP DA TE CAsLAOE
TableAelatdQuewis
an.thesheua).
Aae. ( to
ALTER TABLEtobleKm
DROP toumu
.......eszeeeesnM
ALTER
......J.M..... TABLEtobO
DROP CoLUMN tol
aeeeeeesecsetr.
RENAME Table
ALTERTABLE tabl uame
RENAMETO Hw-tobl nan
CHANGECoumnenawe)
ALTER TABLE table name
CHANGECOLUMNoldMame Ban datadyj
DOMS
Thucat (to delite tabu's dota )
Taucat Table tabe uane
faactiu pustros.
DuH u d u t tabe
g.*.............L
warls
-Joius SL
Joiu iA sd Dmbine Aows
o..Zwo. woetabes basedDu
...alotdcouuu bweytum
id id Salay
162 |.0 3
toqt cotnsu,
ol ioimatiauA....
Tyþu Joias Venn Jingtaut).
Joiu.
outi
Riglut joi
Pulloiu