You are on page 1of 2

DDCE, F.M.

UNIVERSITY
MCA 4th Semester LAB Assignment
MCSL-044

Part -1
1.
2.
3.
4.
5.
6.
7.
8.
9.
10.

UNIX/LINUX LAB

Write a shell script for Calculating factorial of given number


Write a shell script for Calculating average of given numbers on
command line args
Write a shell script to print given numbers sum of all digit
Write a shell program to concatenate two strings and find the length of
the resultant string
Write a shell program to check whether a given string is palindrome or
not.
Write a shell program to find the sum of the series sum=1+1/2++1/n
Write a shell script to find the smallest of three numbers
Write a shell script to generate fibonacci series
Shell Script to check whether given year is leap year or not
Write Script, using case statement to perform basic math operation as
follows
+ addition
- subtraction
x multiplication
/ division

Part -2

ADBMS Lab

1. (a).Write the SQL commands to Create Table of following Structure


Field Name
Customer_ID
Customer_Name
Customer_Address
Customer_City
Customer_State
Zip

Table Name :- CUSTOMER_T


Datatype & Size
Constraints
number(11,0)
primary key
varchar2(25)
not null,
varchar2(30),
varchar2(20),
varchar2(2),
varchar2(9),

(b) Write the SQL commands to Insert some sample record


2. (a)Write the SQL commands to Create Table of following Structure
Field Name
Order_ID
Order_Date
Customer_ID

Table Name :- ORDER_T


Datatype & Size
NUMBER(11,0)
DATE
NUMBER(11,0),

Constraints
primary key
not null,
foreign key

(b) Write the SQL commands to Insert some sample record

3.

(a) Write the SQL commands to Create Table of following Structure


Table Name :- PRODUCT_T

4.

Field Name

Datatype &
Size

Constraints

PRODUCT_ID

INTEGER

primary key

PRODUCT_DESCRIPTION

VARCHAR2(50)

PRODUCT_FINISH

VARCHAR2(20)

STANDARD_PRICE

DECIMAL(6,2)

PRODUCT_LINE_ID

INTEGER

CHECK
(PRODUCT_FINISH
IN ('Cherry',
'Natural Ash',
'White Ash', 'Red
Oak', 'Natural Oak',
'Walnut'))

(b) Write the SQL commands to Insert some sample record


(a) Write the SQL commands to Create Table of following Structure
Table Name :- ORDER_LINE_T
Field Name

Datatype &
Size

ORDER_ID

NUMBER(11,0)

PRODUCT_ID

NUMBER(11,0)

ORDERED_QUANTITY

NUMBER(11,0)

Constraints

primary key & foreign key

(b) Write the SQL commands to Insert some sample record


Show product id and finish for all products
Show product id and finish for all products, sort by product_line_id by
ascending order
7. Show product id and finish for all products, sort by product_line_id by
descending order
8. Show each product_line_id and the total number of products for the
product_line_id
9. Show product_id and description for all products whose names contain a
string of "table"
10. Change a product_description from 'Duplex Table Lamp' to 'Arch Table
Lamp'
11. Show dates and how many orders received in each individual day
5.
6.

THE LAB RECORD MUST BE HAND WRITTEN ON SINGLE SIDE OF PAGE WITH
PROPER DETAILS LIKE PAPER CODE, SUBJECT,EXAM. ROLL NO, SIGNATURE etc.

You might also like