0% found this document useful (0 votes)
4 views6 pages

SQL

class notes of sql basics

Uploaded by

rohitny273
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
0% found this document useful (0 votes)
4 views6 pages

SQL

class notes of sql basics

Uploaded by

rohitny273
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
len > aug. 5 (3G) os Hysal fecatigeh ple fe seve data (datobans | + PlysOu Data: x - Ovad. db Ft is nothing bal me “nen + longo db (kd) sh ne Coll ection ob Trhormation Y aa »DBr Dehobae: — ue whe we can store data. in te detabar x Dalotypr_in aL + Gt spedsin which type Bh thetnaben DD Alter, trumeke, drop os Truck » Updite , Ale (Ga Htipiin Hes) Dal aa Sch i) (Bala ques lens) iv) = Commit , roll back , Gasepoith Cees ee f Gentvel lang) v) EDGk > Grvasnk , yao ke (Data contre) lag) ‘cannes wih CamScanet 2 1) DOL (Dala Definition Jamguage > | ) Ficct dafine the dala in The form of tables «feed «Alen « deop Trameahe OCud 5 & Oe Gk _* table ic in @ a Syrten: Creche iN Hable naamon(Atbibate dekatype , Attwbite datatype sized) ; Ex Creat: table Employee C id int, Dome Taeeaetic) , duignation vanchan(20), id int Ge) 5 wreng [Link] int , puta Cieey doy dak st Be) How Hor creabi Databav Cueal. dedabae — moming ; Use ing poe al 7 chow databases , | sre fables; ME ~Lomivobiy ic important ot the amd. when uring Ply sal commana Line Clank » | + SQL is ia ae - ‘ Upper er owen com down mallir ) x to dwaibe table disc table name ; 29; dtsC Employee , (ov) diac smplogee 7 (beth oe came in q\) © Alter: Gt is tid to ds ble » add coluran in arising ta + drop th column ona tee column Pokily data Wyre tee (Bok Gag clone in twisting table ADD yen @lte table table nan Column name datodypes Fg: Alter table Employer add. adda vanchan/>); (0) To add (rrultigls) columns in wxisting fable : Syotye alin table fable name ADD columns datelypr, ADD Clumna datatype eo alin table Employee add —Jocakion vanchan(is) adh deportes mann relents), ‘Scanne wih CamScanet Ta Haw te dopo sale col Syntax Alten table fable nays drop Cola n 24 Altar table Employee Wop location ; i iple col —— syntax: Alten table table name drop Colmar drop Colnarnt 2 y Ga v) How tp YONG | column’: Eee a aE Colunmn ynlox : Aller. table taBltname Yoname oldcclurmn to new Columnname 5 (olunnn 4g. Alta table areployet Vee ad Gres smployer id 5 vi) Te rename mulliple coluanns - OS SS we Syrtor (Vian table table name venanme Column old colummname to naw column nem, Yararme Column oldcclname f paw clnam , ‘cannes wih CamScanet if. a 1Z2 = ni) Pewee IR Se ssynbr | Altir table fable name modidy Columan name ddaiype (rune), £5: ablin + n table eb) ena modity name varchin(38 — tomployee C prwiewly ait wos 20 , nw changed (veachan size) to 30) [Dep Q Fuca 7 |ein J vavilen Nyenchon = “K Cocid , cram. FAsc , barn name , ae Creal _omthn Tabe ont on bremeh ml) von Jae - Dota amipslabion Fangs ) — i) update) lie ‘cannes wih CamScanet

You might also like