Professional Documents
Culture Documents
SQL Notes New 2022
SQL Notes New 2022
Select x from sterby 7 : — ‘
sT Name TAB TYPE Clustered ; 4
bere “TABLE |
EMP TABLE “
Bonus TABLE is
SAL GRADE TABLE
SQL> Select from Gtje 8 i
Thame TAB TYP clustered
= Sas Na st Stebbins SAC
ae ad
EMP TABLE ;
gonus on
SALGRAPE = TABLE. ee
& All 1 He ones NSn2ig. Sinn
i eae in the
OAM AG)© gyre
pese table name; *
peseriibe : evs cr 9 Name
: Emp ni +
wR SQL ade Sc adept; Pre veaae c
Name - sauvdh, Siab, ee
BEPENe 0) ula aa
pname ST sbtkabed 2s
Loa “4 a ‘SAL pre tnt
SRL) desc emp * % pie < pe
ete En oll the sable infSmation that is
in oa table use the bela syntat” ©
select SE Fpl. name; % 280 =I
puch theists erga eae
SAL > Seledt “ye -frem dept;
bepeNO — . D-Name
- oft iA =e Bunting
Newyork: sdar +
“to
ee 3-K Ss eee we’ i ets
Lo | Peseoreh Patt. ac
Raed
20 /
Sales chico itenoastinn. :
Boston.
40 3
epaationsle To get Particuley column infSvretion Pron) |
the table Use below syntart !
Ari 2 Select column name -frero “table name;
(8) write 2 query to display all the emplojee nam
Fron emplojce table pe ee
Sete sia free Fon ne
(@> write = “quarto display ol) the emplojec
names along With their salary details.
je F Selec; Enamé, = -freca epi |
Ss
|) Sou if ret a cece sersitive, rea i
(2. enewing table name. aie elrOn nears is,
i mandatby-
2 SQL atwrys ends with seeaiDion C84 80
| Table name end column names — a Jin He
s@L should be ere as te ise _ Present in the
d
ee
isinprite — Mery to dicplay oJ) the eraployee
0) 6 along With their
ooo maPeES
gto Select YC than “table;
Salary increased by
4 prite a query to display all -the emplojée
cy mes aleng with their
ne
annual salary.
/é6 OL > Select erkmé capelr Bain amp]
) prite a Wer +o display al) -the enphiee
nares ateng ” ioith “their “dedly. ‘colony
ea Select Ename, gy) / 2p" ee si i?
(ay -
Sel mee ih
Sat Pre
rysklans Tica a
(9) write ot ~ alee ee the ore
names clang |, sane heir Salary erat
Bospeve TOT ibs CD tae ae aemed (or7 | ep
arg, - coloumn *
— number te
wm .
be. elivided. with
ado . on ia
Aliasirg— 2 yey - “a
Giving ‘anather rome’ to the existing -Colosee
name. C8) table name wil). be called ac