FYBSc-COMPUTER-SCIENCE-SEM2 - Slip
FYBSc-COMPUTER-SCIENCE-SEM2 - Slip
FYBSc-COMPUTER-SCIENCE-SEM2 - Slip
Q 3) Viva [5 marks]
Slip 1
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 2
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 3) Viva [5 marks]
Slip 3
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute any two of the following using PL/pgSQL [10 marks]
i. Write a function which will accept the movie name as input and
prints its release year and budget.
ii. Write a function using cursor, which will accept the actor name
and print the names of all movies in which that actor has acted.
iii. Write a trigger which will be executed whenever an actor is
deleted from the actor table, display appropriate message.
Q 3) Viva [5 marks]
Slip 4
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute any two of the following using PL/pgSQL [10 marks]
i. Write a function which accepts account no as input and prints
the details of that account.
ii. Write a function using cursor which accepts customer name and
prints all account details of that customer. If the customer name
is invalid, print appropriate message.
iii. Write a trigger which is executed whenever update is made to
the account table. If the balance becomes less than 1000, print an
error message that balance cannot be less than 1000.
Q 3) Viva [5 marks]
Slip 5
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 6
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute any two of the following using PL/pgSQL [10 marks]
i. Write a function which accepts employee name and prints the
details of the project which the employee works on.
ii. Write a trigger which will be executed whenever insertion is
made to the employee table, if age is less than 21, insertion
should not be allowed.
iii. Write a function using cursor which will accept the project name
and display the names of employees working on that project.
Q 3) Viva [5 marks]
Slip 7
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute any two of the following using PL/pgSQL [10 marks]
i. Write a function which will display the details of the teacher
having maximum experience.
ii. Write a stored function using cursor which will accept the
subject name and print the names of all teachers teaching that
subject.
iii. Write a trigger before insert/update on Teacher table. Age
should not be < 21. Print an appropriate message.
Q 3) Viva [5 marks]
Slip 8
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute Any two of the following using PL/pgSQL [10 marks]
i. Write a function to display the item name with maximum
quantity.
ii. Write a cursor to display the names of suppliers in ‘Pune’ city.
iii. Write a trigger before insert or update on rate field. If the rate is
less than or equal to zero then raise appropriate exception.
Q 3) Viva [5 marks]
Slip 9
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 10
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
OR
Q 1) A Write a program to accept details of n employees (id, name, salary). [15 marks]
Display all the details. Also, search for an employee by name.
Slip 11
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
OR
Q 1) A Write a C program to create a structure named book (book_name, [15 marks]
author_name and price) and display all book details having price > ____
in a proper format by passing the structure array as function argument.
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute Any two of the following using PL/pgSQL [10 marks]
i. Write a function to accept department city as input and returns
the total number of departments in that city.
ii. Write a cursor to display the department-wise names of
employees whose salary is between 50000 and 70000.
iii. Write a trigger before inserting an employee record in the
Employee table. Raise an exception if salary < 0.
Q 3) Viva [5 marks]
Slip 12
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
OR
Q 1) A Write a C program that accepts a string and character to search. The [15 marks]
program will call a function, which will search for the position of
occurrence of the character in the string and return its position. Function
should return –1 if the character is not found in the string.
Slip 13
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 14
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute Any two of the following using PL/pgSQL [10 marks]
i. Write a function to accept department name and display the
average salary of employees in that department.
ii. Write a cursor to display the names of employees who works in
“HR” department.
iii. Write a trigger before updating an employee record in the
Employee table. Raise a notice and display the message
“Employee record is being updated”.
Q 3) Viva [5 marks]
Slip 15
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 16
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 1) A i. Write a program to find the length of a string using standard library [5 marks]
function.
ii. Write a program to read a text file and display all the characters such [10 marks]
that the case is reversed (upper to lower and lower to upper case).
OR
Q 1) A Write a program to accept ‘n’ employee details (eno, ename, salary) and [15 marks]
display all employee details whose salary is more than 10000, by passing
array of structure to the function.
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute any two of the following using PL/pgSQL [10 marks]
i. Write a trigger before insert the record of the student in the Student
table. If the Roll_No is less than or equal to zero then the trigger
gets fired and displays the message “Invalid Roll Number”.
ii. Write a cursor to accept the student's name from the user as an
input and display names of all teachers teaching that student.
iii. Write a stored function to count the number of teachers having
experience > 10 years
Q 3) Viva [5 marks]
Slip 17
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 1) A i. Write a program to calculate area of a circle. Use macro for PI. [5 marks]
ii. Write a program to perform the following operations on strings using [10 marks]
standard library functions:
a. Copy one string to another
b. Convert a string to uppercase.
OR
Q 1) A A file “student.txt” contains rollno, name and total_marks. Write a [15 marks]
program to read this file to display all student details on screen.
Slip 18
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 1) A i. Write a C program to store the information of one person as his Pancard [5 marks]
number or Aadhar card number using union.
ii. Write a program to copy contents of one file to another. [10 marks]
OR
Q 1) A Write a menu driven program using standard library function [15 marks]
To find Length of string
To compare two strings
To copy one string to other.
To concatenate two strings
Q 3) Viva [5 marks]
Slip 19
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 3) Viva [5 marks]
Slip 20
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 3) Viva [5 marks]
Slip 21
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 22
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 23
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 1) A i. Write a program to accept a string and an index from user and [5 marks]
displays the character at that specific index.
ii. Write a program to accept the name of a file as command line [10 marks]
argument and display the contents of that file.
OR
Q 1) A Write a program to accept details of ‘n’ books (bno, bname, price). [15 marks]
Display all the details. Also display all books having price > p.
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute any two of the following using PL/pgSQL [10 marks]
i. Write a function which will give the average charges of an actor.
ii. Write a function using cursor, which will accept the movie name and
prints the names of all actors in that movie.
iii. Write a trigger which will be executed whenever a movie is deleted
from the movie table, display appropriate message.
Q 3) Viva [5 marks]
Slip 24
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 25
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 26
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute any two of the following using PL/pgSQL [10 marks]
i. Write a stored function using cursors to accept person name as input
and print company names and shares owned by that person.
ii. Write a stored function to update the share_values by 20% for Person
“____”.
iii. Write a trigger before deleting company record. Display appropriate
message to the user.
Q 3) Viva [5 marks]
Slip 27
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 28
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute any two of the following using PL/pgSQL [10 marks]
i. Write a stored function using cursors, to accept Item name from the
user and display the Rate and Supplier Name for that Item.
ii. Write a stored function to delete records of the Item name “PEN”.
iii. Write a trigger before update on rate field. If the difference in the old
rate and new rate is more than Rs 2000, raise an exception and
display the corresponding message.
Q 3) Viva [5 marks]
Slip 29
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute any two of the following using PL/pgSQL [10 marks]
i. Write a function which accepts customer name as input and counts
the total number of accounts of that customer.
ii. Write a function using cursor which accepts city name as input and
prints the details of all customers in that city
iii. Write a trigger which does not allow deletion of accounts of ___
type.
Q 3) Viva [5 marks]
Slip 30
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute Any two of the following using PL/pgSQL [10 marks]
i. Write a function to accept department name and return the
number of employees of that department.
ii. Write a cursor to accept salary as input and display the names of
employees having salary > that value.
iii. Write a trigger after insert on an employee record. Display
appropriate message when the record is inserted.
Q 3) Viva [5 marks]
Slip 31
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 32
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute any two of the following using PL/pgSQL [10 marks]
i. Write a function which accepts the model name and prints all
cars of that model.
ii. Write a trigger before insert/update on Driver. Raise
exception if driver age is < 21.
iii. Write a cursor which accepts the driver name and prints the
details of all cars that this driver has driven, if the driver
name is invalid, print an appropriate message.
Q 3) Viva [5 marks]
Slip 33
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 34
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 3) Viva [5 marks]
Slip 35
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 36
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute any two of the following using PL/pgSQL [10 marks]
i. Write a trigger before insert/update on Doctor. Raise exception
if charges are <0.
ii. Write a function which will accept the name of the hospital and
calculate the average charges of doctors visiting that hospital.
iii. Write a function using cursor to accept the specialization and
print the details of all doctors with that specialization.
Q 3) Viva [5 marks]
Slip 37
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Q 2) A Create the above database in PostGreSQL and insert sufficient records. [5 marks]
B Execute Any two of the following using PL/pgSQL [10 marks]
iv. Write a function to accept department name and display the
maximum salary of an employee in that department.
v. Write a cursor to display the department-wise names of all
employees.
vi. Write a trigger before insert/update on an employee record.
Raise exception if salary <0.
Q 3) Viva [5 marks]
Slip 38
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 39
Savitribai Phule Pune University
F.Y.B.Sc. Computer Science Practical Examination
Semester II (2019 pattern)
Laboratory Course CS-123
(Advanced ‘C’ Programming & Relational Database Management Systems)
Duration: 3 Hours Maximum Marks: 35
Slip 40