Professional Documents
Culture Documents
Vishesh Malhota
INDEX
SERIAL NO. 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 PRACTICAL TOPIC CREATE TABLE INSERT DATA RETRIEVING RECORDS UPDATING RECORDS DELETING RECORDS ALTERING TABLE DELETING TABLE RENAMING TABLE PATTERN MATCHING AGGREGATE FUNCTIONS LOGICAL OPERATORS SELECTING DATA FRAMES TABLES LISTS TEXT FORMATTING ADDING AN IMAGE HYPERLINKING FEEDBACK FORM MS-EXCEL MS-DOS PAGE NO 3 8 16 20 22 24 26 28 30 32 34 36 38 41 45 49 52 55 59 62 67 Remar ks
VISHESH MALHOTRA
Page 2
PRACTICAL 1
VISHESH MALHOTRA
Page 3
CREATE TABLE
A)CLIENT_MASTER
COLUMN Name CLIENT NO NAME ADDRESS 1 CITY PINCODE STATE BALDUE DATA TYPE VARCHA R2 VARCHA R2 VARCHA R2 VARCHA R2 NUMBER VARCHA R2 NUMBER SIZ E 6 20 30 15 8 15 10, 2
QUERY SQL> Create table CLIENT_MASTER (ClientNoVarchar2(6), Name Varchar2(20), Address Varchar1(30), City Varchar2(15), PincodeNumber(8), State Varchar2(15), BaldueNumber(10,2)); Table created.
VISHESH MALHOTRA
Page 4
B)PRODUCT_MASTER
COLUMN NAME PRODUCT NO DESCRIPTIO N PROFITPERC ENT UNITMEASUR E QTYONHAND REORDERLV L SELLPRICE COSTPRICE DATA TYPE VARCHA R2 VARCHA R2 NUMBER VARCHA R2 NUMBER NUMBER NUMBER NUMBER SI ZE 6 15 4,2 10 8 8 8,2 8,2
QUERY: SQL> Create table PRODUCT_MASTER (ProductNoVarchar2(6), Description Varchar2(15), ProfitPercentNumber(4,2), UnitMeasureVarchar2(10), QtyOnHandNumber(8), ReOrderLvlNumber(8), SellPriceNumber(8,2), CostPriceNumber(8,2));
VISHESH MALHOTRA
Page 5
Table created.
C)SALESMAN_MASTER
COLUMN NAME SALESMANNO SALESMANNA ME ADDRESS1 ADDRESS2 CITY PINCODE STATE SALAMT TGTTOGET YTDSALES REMARKS DATA TYPE VARCHA R2 VARCHA R2 VARCHA R2 VARCHA R2 VARCHA R2 NUMBER VARCHA R2 NUMBER NUMBER NUMBER VARCHA R2 SI ZE 6 20 30 30 20 8 20 8,2 6,2 6,2 60
QUERY: SQL> Create table SALESMAN_MASTER (SalesmanNoVarchar2(6), SalesmanNameVarchar2(20), Address1 Varchar2(30), Address2 Varchar2(30),
VISHESH MALHOTRA Page 6
City Varchar2(20), PincodeNumber(8), State Varchar2(20), SalAmtNumber(8,2), TgttogetNumber(6,2), YtdsalesNumber(6,2), Remarks Varchar2(60)); Table created. D)SALES_ORDER
COLUMN NAME CLIENTNO ORDERNO ORDERNAME ORDERDATE ORDERQTY DATA TYPE VARCHA R2 VARCHA R2 VARCHA R2 DATE NUMBER SI ZE 6 10 10 6
QUERY: SQL> Create table SALES_ORDER (ClientNoVarchar2(6), OrderNoVarchar2(10), OrderNameVarchar2(10), OrderDate Date, OrderQtyNumber(6)); Table created.
VISHESH MALHOTRA Page 7
PRACTICAL 2
VISHESH MALHOTRA Page 8
INSERT DATA
A)INSERT INTO CLIENT MASTER QUERY: Client No Name Address1 City B-10 45-B P-7 49-B A/10 216/B
Page 9
Baldue
C00001 Ivan Bayross C00002 MamtaMuzumda r C00003 ChhayaBankar C00004 Ashwini Joshi C00005 Hansel Colaco C00006 Deepak Sharma
VISHESH MALHOTRA
Solution: SQL> Insert into client_master values('C00001','Ivan Bayross', B10,'Mumbai',400054,'Maharashtra',15000); 1 row created.
SQL> Insert into client_master values('C00002','Mamta Muzumdar', 45B,'Madras',780001,'Tamil Nadu',0); 1 row created.
1 row created.
QUERY: Product No Description Profit Unit Oty on Hand 200 150 100 100 150 80 100 50 50 20 20 50 30 40 350 500 600 750 850 700 350 250 350 450 500 550 450 250 Reorder Sell Level Cost
Percent Measur e T-Shirts Shirts Cotton Jeans Jeans Trousers Pull Overs Denium 5 6 5 5 2 2.5 4 Piece Piece Piece Piece Piece Piece Piece
Price Price
VISHESH MALHOTRA
Page 11
Shirts P07975 P08865 Solution: SQL> Insert into product_master values('P00001','TShirts',5,'Piece',200,50,350,250); 1 row created. Lyrca tops Skirts 5 5 Piece Piece 70 75 30 30 300 450 175 300
SQL> Insert into product_master values('P0345','Shirts',6,' Piece',150,50,500,350); 1 row created. SQL> Insert into product_master values('P06734','Cotton Jeans',5,'Piece',100,20,600,450); 1 row created.
SQL> Insert into product_master values('P07975','Lycra Tops',5,'Piece',70,30,300,175); 1 row created. SQL> Insert into product_master values('P08865','Skirts',5,' Piece',75,30,450,300); 1 row created
QUERY: Salesman No Name S00001 S00002 S00003 S00004 Aman Address1 Address2 City A/14 Worli Nariman Bandra Juhu Mumba i Mumba i Mumba i Mumba i Pincode State 400002 400001 400032 400044 Maharashtra Maharashtra Maharashtra Maharashtra
Solution: SQL> Insert into salesman_master values('S00001','Aman','A/14','Worli','Mumbai',400002,'Maharashtra',3000,100,50, 'Good'); 1 row created. SQL> Insert into salesman_mastervalues('S00002','Omkar',65,'Nariman','Mumbai',400001,'Maharas htra',3000,200,100,'Good'); 1 row created SQL> Insert into salesman_master values('S00003','Raj','P7','Bandra','Mumbai',400032,'Maharashtra',3000,200,100,'Good'); 1 row created.
VISHESH MALHOTRA
Page 14
QUERY: CLIENTNO C00001 C00002 C00003 ORDERNO O00001 O00002 O00003 ORDERNAME ORDERDATE ORDERQTY T-Shirts Jeans Skirts 12-June-2010 10-May-2010 20-June-2010 10 9 5
VISHESH MALHOTRA
Page 15
PRACTICAL 3
VISHESH MALHOTRA Page 16
RETRIEVING RECORDS
a) b) c) d) e) f) Find out the names of all the clients. Retrieve the entire contents of the client_master table. Retrieve the list of names, city and state of all the clients. List the various products available from the product_master table. List all the clients who are located in Mumbai. Find the names of salesman who have a salary to Rs. 3000.
VISHESH MALHOTRA
Page 17
-------------------Ivan Bayross MamtaMuzumdar Chhaya Banker Ashwini Joshi Hansel Colaco Deepak Sharma
6 rows selected.
AD D1
B/10 45-B
CITY
MUMBAI MADRAS
PINCO DE
400054 780001
STATE
MAHARASHTR A TAMIL NADU
BAL DUE
1500 0 0
MUMBAI
400057
5000 0 2000
VISHESH MALHOTRA
Page 18
C00006
DEEPAK SHARMA
216/ B
MANGALOR E
560050
KARNATAKA
c) SQL> select name, city, state from client_master; NAME Ivan Bayross CITY Mumbai STATE Maharashtra Tamil Nadu Maharashtra Karnataka Maharashtra
MamtaMuzumdar Madras Chhaya Banker Ashwini Joshi Hansel Colaco Deepak Sharma 6 rows selected Mumbai Bangalore Bangalore
Mangalore Karnataka
d) SQL> select description from product_master; DESCRIPTION T-Shirts shirts Cotton Jeans Jeans Trousers Pull Overs Denim Shirts Lycra Tops
VISHESH MALHOTRA Page 19
Skirts 9 rows selected. e) SQL> select name from client_master where city='Mumbai'; NAME Ivan Bayross Chhaya Banker Hansel Colaco
f) SQL> select Salesmanname from salesman_master where Salamt=3000; SALESMANNAME Aman Omkar Raj
VISHESH MALHOTRA
Page 20
PRACTICAL 4
UPDATING RECORD
a) Change the city of clientno C00005 to BANGALORE. b) Change the BALDUE of CLIENTNO C00001 to 1000. c) Change the Cost Price TROUSERS to Rs.950. d) Change the city of the sales man to PUNE.
SOLUTION:
VISHESH MALHOTRA
Page 21
VISHESH MALHOTRA
Page 22
PRACTICAL 5
DELETING RECORD
a) Delete all salesman from the SALEMAN_MASTER whose salaries are equal to Rs.3500. b) Delete the product from PRODUCT_MASTER where the QtyOnHand=100. c) Delete from CLIENT_MASTER where the column STATE holds the value Tamil Nadu.
1 row deleted.
VISHESH MALHOTRA
Page 24
PRACTICAL 6
ALTERING TABLE
a) Add a column called TELEPHONE of datatype Number and size ='10' to the client_master table. b) Change the size of SellPrice column in product_master to 10,2.
Solution: a) SQL> Alter table client_master Add Telephone Number(10); Table altered.
VISHESH MALHOTRA Page 25
VISHESH MALHOTRA
Page 26
PRACTICAL 7
DELETING TABLE
a) Destroy the table client_master along with its data. SOLUTION: a) SQL> Drop table client_master; Table dropped.
VISHESH MALHOTRA
Page 27
VISHESH MALHOTRA
Page 28
PRACTICAL 8
RENAMING TABLE
a) Change the name of the saleman_mastertble to sman_mast. SOLUTION: a) SQL> Rename salesman_master to sman_mast; Table renamed.
VISHESH MALHOTRA
Page 29
VISHESH MALHOTRA
Page 30
PRACTICAL 9
PATTERN MATCHING
a) List the Names of all the client having 'a ' as the second letter in their names. b) List the client who says in a city whose first letter is 'm'. SOLUTION:
VISHESH MALHOTRA Page 31
a) SQL> Select Name from client_master where name LIKE '_a%'; NAME Hansel Colaco
SOLUTION: b) SQL> Select clientno, clientname from client_master where city LIKE 'm%'; CLIENTNO NAME C00001 C00003 C00006 IVAN BAYROSS CHHAYA BANKAR DEEPAK SHARMA
VISHESH MALHOTRA
Page 32
PRACTICAL 10
AGGREGATE FUNCTIONS
a) Count the total number of orders. b) Calculate the average price of all the product. c) Determine the maximum and minimum product price. Rename the output as max_price and min_price respectively.
VISHESH MALHOTRA Page 33
SOLUTION: a) SQL> Select Count(*) from sales_order; COUNT(*) 3 SOLUTION: b) SQL> Select Avg(CostPrice) from product_master; Avg(CostPrice) 412.5 SOLUTION: c) SQL> Select Max(CostPrice) as Max_Price, Min(CostPrice) as Min_Price from product_master; Max_PriceMin_Price 950 175
VISHESH MALHOTRA
Page 34
PRACTICAL 11
LOGICAL OPERATORS
a. List the order information for ClientNo C00001 and C00002. b. List products whose selling price is greater than 500 and less than or equal to 750.
VISHESH MALHOTRA
Page 35
SOLUTION: a) SQL> select * from sales_order where Clientno IN ('C00001','C00002'); CLIENT ORDERNO ORDERNAME ORDERDATE ORDERQTY C00001 C00002 O00001 O00002 T-Shirts jeans 12-JUN-10 10-MAY-10 10 9
SOLUTION: b) SQL> Select Description from product_master where SellPrice> 500 AND SellPrice<= 750; DESCRIPTION PULL OVERS
VISHESH MALHOTRA
Page 36
PRACTICAL 12
SELECTING DATA
a. List all clients who stay in Bangalore or Mangalore. SQL> Select Name from client_master where City IN('Bangalore','Mangalore');
VISHESH MALHOTRA Page 37
b. List all clients whose BalDue is greater than value 10000. SQL> Select Name from client_master where BalDue>10000; NAME IVAN BAYROSS
c. List the names,city and state of clients who are not in the state of Maharashtra. SQL> Select Name, City, State from client_master where State NOT IN('Maharashtra'); NAME CITY STATE ASHWINI JOSHI DEEPAK SHARMA BANGALORE MANGALORE KARNATAKA KARNATAKA
VISHESH MALHOTRA
Page 38
PRACTICAL 13
CODING:
<html> <head> <title>frame</TITLE> </head> <frameset rows="10%,90%"> <frame src="OXFORD.html"> <frame src="OXFORD.jpg"> </frameset> </html>
OUTPUT:
VISHESH MALHOTRA
Page 40
VISHESH MALHOTRA
Page 41
PRACTICAL 14
VISHESH MALHOTRA
Page 42
TABLES
CODING:
<HTML> <head> <title>NIEC</TITLE> </head> <body><H1>TABLES</H1></body> <TABLE BORDER="12"> <tr bgcolor="YELLOW"> <TD>SUBJECT</TD> <TD>FACULTY NAMES</TD></TR> <tr bgcolor="PINK"> <TD> AFM</TD> <TD>DK GUPTA</TD></TR> <tr bgcolor="blue"> <TD> ME</TD> <TD>VANDANA GAUR</TD></TR> <tr bgcolor="RED"> <TD>BC</TD> <TD>SHWETA SHARMA</TD></TR>
VISHESH MALHOTRA Page 43
<tr bgcolor="GREEN"> <TD>BLE</TD> <TD>ASHIMA KAPOOR</TD></TR> <tr bgcolor="ORANGE"> <TD>ITM</TD> <TD>SUCHI SHRIVASTAVA</TD></TR> <TD>MPOB</TD> <TD>PRIYANKA SHARMA</TD> </TABLE> </html>
VISHESH MALHOTRA
Page 44
OUTPUT:
VISHESH MALHOTRA
Page 45
PRACTICAL 15
VISHESH MALHOTRA
Page 46
LISTS
CODING:
<html> <head> <title>COURSES OFFERED UNDER OXFORD UNIVERSITY</TITLE> <BODY> <I> <B> <FONT SIZE=12 COLOR = "BLUE"> COURSES OFFERED UNDER OXFORD</I></B></FONT></BODY><OL> <LI>RESEARCH IN HUMANITIES <LI>EXPERIMENTAL PSYCHOLOGY <LI>CLASSIC AND ENGLISH <LI>COMPUTER SCIENCE <LI>APPLIED PHYSICS</OL> <BODY> <I> <B> <FONT SIZE=12 COLOR ="RED"> FACILITIES PROVIDED </I></B></FONT></BODY> <UL> <LI> Central Library <LI> Computer Centre <LI>Workshop & Laboratories <LI>WI FI ENABLED CAMPUS</UL> <dl> <dt> <B> <FONT SIZE=12>OXFORD DETAILS</I></B></FONT>
VISHESH MALHOTRA Page 47
<DD> <B> <FONT SIZE=3 COLOR = "GREEN"> The University of Oxford (informally Oxford University or Oxford) is a university located in Oxford, United Kingdom. It is the second-oldest surviving university in the world and the oldest in the English-speaking world. Although its exact date of foundation is unclear, there is evidence of teaching as far back as 1096. The University grew rapidly from 1167 when Henry II banned English students from attending the University of Paris. In post-nominals, the University of Oxford was historically abbreviated as Oxon. (from the Latin Oxoniensis), although Oxf isnowadays used in official university publications.After disputes between students and Oxford townsfolk in 1209, some academics fled north-east to Cambridge, where they established what became the University of Cambridge. The two ancient English universities have many common features and are often jointly referred to as Oxbridge. In addition to their cultural and practical associations, as a historic part of British society, they have a long history of rivalry with each other.Most undergraduate teaching at Oxford is organised around weekly tutorials at selfgoverning colleges and halls, supported by lectures and laboratory classes organised by University faculties and departments. League tables consistently list Oxford as one of the UK's best universities; the university regularly contends with Cambridge for first place in the tables. Oxford consistently ranks in the world's top 10. For more than a century, it has served as the home of the Rhodes Scholarship, which brings students from a number of countries to study at Oxford as postgraduates or for a second bachelor's degree.
VISHESH MALHOTRA
Page 48
OUTPUT
VISHESH MALHOTRA
Page 49
PRACTICAL 16
VISHESH MALHOTRA
Page 50
TEXT FORMATTING
CODING: <html> <head> <title>VISHESH MALHOTRA</title> </head> <Body bgcolor="BLUE"> <h1> <b>VISHESH MALHOTRA</B> </h1> Northern India Engineering College <br> Shastri Park <br> New Delhi <br> <br> <font size="6"> <font color="WHITE"> Pursuing MBA from NIEC is affilated from GGSIPU.</font> </body> </html>
VISHESH MALHOTRA
Page 51
OUTPUT:
VISHESH MALHOTRA
Page 52
PRACTICAL 17
VISHESH MALHOTRA
Page 53
ADDING AN IMAGE
CODING:
<html> <head> <title>TWILIGHT</TITLE> </HEAD> <body> <IMG SRC="TWILIGHT.jpg" width="500" height="500" >
VISHESH MALHOTRA
Page 54
OUTPUT:
VISHESH MALHOTRA
Page 55
PRACTICAL 18
VISHESH MALHOTRA
Page 56
HYPERLINK
CODING: <html> <head> <title>TWILIGHT</TITLE> </head> <body> <FONT face="comic sans MS" size=6 color="BLUE"><B><center>TWILIGHT</B></FONT><br> <FONT face="comic sans MS" size=4 color="CYAN"><B> Twilight is a series of four vampire-themed fantasy romance novels by American author Stephenie Meyer. It charts a period in the life of Isabella "Bella" Swan, a teenage girl who moves to Forks, Washington, and falls in love with a 104-year-old vampire named Edward Cullen. The series is told primarily from Bella's point of view, with the epilogue of Eclipse and Part II of Breaking Dawn being told from the viewpoint of character Jacob Black, a werewolf. The unpublished Midnight Sun is a retelling of the first book, Twilight, from Edward Cullen's point of view. The novella The Short Second Life of Bree Tanner, which tells the story of a newborn vampire who appeared in Eclipse, was published on June 5, 2010 as a hardcover book and on June 7 as a free online ebook. [1] The Twilight Saga: The Official Illustrated Guide, a definitive encyclopedic reference with nearly 100 full colour illustrations, was released in bookstores on April 12, 2011.[2]Since the release of the first novel, Twilight, in 2005, the books have gained immense popularity and commercial success around the world. The series is most popular among young adults; the four books have won multiple awards, most notably the 2008 British Book Award for "Children's Book of the Year" for Breaking Dawn,[3]
VISHESH MALHOTRA
Page 57
while the series as a whole won the 2009 Kids' Choice Award for Favorite Book.</B></FONT><br>
<a href="file:///C:/Documents%20and %20Settings/SONUJAISWAL/Desktop/HOD.HTML>TO VIEW DETAILS ABOUT VAMPIRES ND WOLVES CLICK HERE </body> </html>
OUTPUT:
VISHESH MALHOTRA
Page 58
CLICK ON THE HYPERLINK TO VIEW DETAILS ABOUT VAMPIRES AND WOLVES CLICK HERE THEN IT WILL OPEN THE PAGE:
VISHESH MALHOTRA
Page 59
PRACTICAL 19
VISHESH MALHOTRA
Page 60
FEEDBACK FORM
CODING:
<html> <head> </head> <form method="post" action="destinymaker.1513@rediffmail.com"> <p> Name <input type="text" name="prof" size="20" Maxlength="30"> <p> Place <input type="text" name="prof" size="20" maxlength="30"> <p> City <input type="text" name="prof" size="20" maxlength="30"> <p> State <input type="text" name="prof" size="20" maxlength="30"> <p> Marital Status<br> <input type="radio" name="marital" value="married"> Married <input type="radio" name="marital" value="unmarried"> Unmarried <p> Hobbies<br> <input type="checkbox" name="hob" value="gardening"> Garderning<br> <input type="checkbox" name="hob" value="cricket"> Cricket<br> <input type="checkbox" name="hob" value="reading"> Reading<br> <input type="checkbox" name="hob" value="others"> Others<br> <p> Comments/Suggestions<br>
VISHESH MALHOTRA Page 61
<textarea name="suggestions" rows="5" cols="30" wrap> </textarea> <br> <br> <br> <input type="submit" value="Accept"> <input type="reset" value="Refresh"> </form> </html>
VISHESH MALHOTRA
Page 62
OUTPUT:
VISHESH MALHOTRA
Page 63
PRACTICAL 20
MS-EXCEL
VISHESH MALHOTRA
Page 64
VISHESH MALHOTRA
Page 65
AVERAGE
80 78 76 74 72 70 68 66 64 62 60 1 2 3 4 5 6 7 8 9 10
AVERAG E
PERCENTAGE
80 78 76 74 72 70 68 66 64 62 60 1 2 3 4 5 6 7 8 9 10
PERCENTA GE
SUM(TOTAL)
400 390 380 370 360 350 340 330 320 310 300
SUM(TOTAL)
10
VISHESH MALHOTRA
Page 66
120 100 80 60 40 20 0 RAM SHYAM HEENA LEELA SHUBHI SUNANA SAMEER SANDHYA RUCHI PAYAL ENGLIS H HINDI MATHS SCIENC E LAW
100 90 80 70 60 50 40 30 20 10 0 RAM SHYAM HEENA LEELA SHUBHI SUNANA SAMEERSANDHYA RUCHI PAYAL MAX() MIN()
VISHESH MALHOTRA
Page 67
VISHESH MALHOTRA
Page 68
PRACTICAL 21
VISHESH MALHOTRA
Page 69
MS-DOS
Disk operating System
MS-DOS is a non-graphical command line operating system created for IBM compatible computers that was first introduced by Microsoft in August 1981 and was last updated in 1994 when MS-DOS 6.22 was released. Although the MSDOS operating system is not commonly used today, the command shell more commonly known as the Windows command line is still used and recommended. DOS Commands
A DOS command helps you to give instruction to the operating system in Character User Interface (CUI) environment. Using DOS commands, you can perform various tasks, such as creating and managing files and folders and monitoring your system resources.
To create and manage files and folders, perform the following steps:
1. Click the Start button, and then select Run. 2. In the Run dialog box, type cmd in the Run box. 3. Click the OK button.
VISHESH MALHOTRA
Page 70
In the Command Prompt window, the command is given after the command prompt and the Enter key is pressed to execute the command.
As the drive displayed is the user directory, change the drive to D: drive by giving following command at the command prompt. C:\Users\user>D: Directories DOS uses directories to organize the files on your disks. That means we need to use directory commands to create a structure to store our files, and to find the files we have stored there. The default directory is the Root Directory and contains the minimum DOS files.
VISHESH MALHOTRA
Page 71
The Root Directory cannot show more than 132 files in its directory listing.
Create Directory MD or MKDIR command is used to make directory. Syntax: MD [drive:] [path] [directory name] Or MKDIR [drive:] [path] [directory name] Example: To create a new directory names Tim under C: drive, give following command: C:\>MD Tim or C:\>MKDIR Tim
Changing Directory You can change your working directory by issuing the CD command. Syntax: CD [drive:] [directory name] Example: To make Tim as current directory, give following command: C:\>CD Tim
VISHESH MALHOTRA
Page 72
Deleting Directory RD command is used to remove a directory. Syntax: RD [drive:] [path] Examples: To remove Tim directory from the C: drive, give the following command: C:\>RD Tim
Displaying Contents of a Directory DIR command is used to display the contents of the directory. Syntax: DIR [drive:] [path] [/option] /option stand for various options that can be used with DIR command which are displayed in the following table:
VISHESH MALHOTRA
Page 73
Option /p /w /s
Description Pause after each screenful Uses wide list format Also look in subdirectories
Creating text File COPY CON command is used to create a text file. Syntax: COPY CON [filename]
After the command is given at the command prompt, the cursor goes to the next line. Write the text and press ctrl-Z key together to save the contents in the file. Then, press <Enter> key.
Example: To create a file client.txt under the current folder Tim, give the command: C:\Tim>copy con Client.txt Now, write Hi, How are you?
VISHESH MALHOTRA
Page 74
Displaying the Contents of a File TYPE command is used to display the contents of a file. Syntax: Type [drive:] [path] [filename] Example: C:\Tim>type Client.txt
VISHESH MALHOTRA
Page 75
Renaming File REN command is used to change the name of a file. Syntax: REN [drive:] [path] [file name] [new filename] Example: To change the name of the file Client.txt to Client1.txt, give following command: C:\Tim>REN Client.txt Client1.txt
Copying Files COPY command is used to copy one or more files to an alternate location. Syntax: COPY [source] [destination] Source Specifies the path of the file or files to be copied. Destination Specifies the path of the destination directory. Example: To copy Client1.txt from the current Tim directory to Obama directory, give following command: C:\Tim>copy Client1.txt C:\Obama
Moving Files
VISHESH MALHOTRA
Page 76
MOVE command is used to move a file or files from one location to another location. Syntax: MOVE [drive:] [source] [drive:] [target] Example: To move case1.txt file from directory Tim to the directory Obama, give following command: C:\Tim>move Case1.txt C:\Obama
Deleting Files DEL command is used to delete file or files from the disk. Syntax: DEL [drive:] [path] [filename] Example: To delete Client1.txt from the Tim folder, give following command: C:\Tim>DEL Client1.txt
VISHESH MALHOTRA
Page 77