0% found this document useful (0 votes)
56 views27 pages

Que1:Ingit, The User Configurations On Os Level Can Be Modified by Using Ans

The document contains questions and answers related to version control using Git, SQL, object-oriented programming principles, and UML class diagrams. Some key points addressed include: - Configuring Git user settings using 'git config --global' - The steps to track a new file in Git - How classes are represented in UML - Finding courses taught in multiple semesters using SQL - Deleting branches in Git using 'git branch -d' - Valid constraint types in databases - Object-oriented principles like encapsulation and method overriding
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
56 views27 pages

Que1:Ingit, The User Configurations On Os Level Can Be Modified by Using Ans

The document contains questions and answers related to version control using Git, SQL, object-oriented programming principles, and UML class diagrams. Some key points addressed include: - Configuring Git user settings using 'git config --global' - The steps to track a new file in Git - How classes are represented in UML - Finding courses taught in multiple semesters using SQL - Deleting branches in Git using 'git branch -d' - Valid constraint types in databases - Object-oriented principles like encapsulation and method overriding
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 27

Que1:InGIt, the user configurations on OS level can be modified by using

Ans:git config --global

Que2:Choose the correct sequence of command from following to track a file.


(Assume file is being tracked for first time)

Ans:gitinit
git add <filename.extension>
git commit -m <message>

Que3:In UML how is class represented?

ANS:Rectangle with 3 partitions

Que4:Which query should be used to find all the courses taught in both the 'Fall 2013' semester
and in the 'Spring 2014' semester .

Ans:
Select distinct courseid
from section
where semester = 'Fall' and year= 2013 and
courseid in (select courseid
from section
where semester = 'Spring' and year= 2014);

Que5:Which of the following is correct command to delete a branch

Ans:git branch -d 'branch_name'

Que6:What are valid constraint types? (Choose Multiples)

Ans:
1) NOT NULL

2) UNIQUE
4) PRIMARY KEY
5) CHECK
Que7:Examine the description of the STUDENTS table:

STD_ID NUMBER(4)
COURSE_ID VARCHAR2(10)
START_DATE DATE
END_DATE DATE

Which aggregate functions are valid on the START_DATE column?


1) MIN
2) COUNT
5) MAX

Que8:The class model of Formatter in the figure demonstrates which Object


Oriented principle(s)

Ans: 3) Method Overriding

Que9:Which one of the following statements describes "Encapsulation"?


Ans;1) All the attributes and methods of every class need to be private.
2) All the attributes and operations of every class need to be public
3) All the data for an application should be in one class and all the operations for application
should be collected in another class. In general class should either contain attributes or
operations but not both.
4) The methods and the data (attributes) on which they operate needs to be kept together in one
class.

Que10:Which one of the following aspect is NOT covered in class model?


Ans:4) When specific operation was invoked by other class
Que11:State True or False:-

Merging means to take all your work from other branch to main branch.
Ans:2) TRUE

Que12:What is staging area or index in GIT?


select all matching/correct options.
1) An intermediate area to format and review
2) Area where merging takes place before pushing to remote
3) Area which can act like cache to review
4) Area where commits are stored

Que13:The EMP table has these columns:


ENAME VARCHAR2(35)
SALARY NUMBER(8,2)
HIRE_DATE DATE
Management wants a list of names of employees who are hired in 2011 or 2012 and
whose salary in the range of 60000 to 100000. Which SQL statement displays the
required results?
Ans:
3) SELECT ENAME
FROM EMP
WHERE to_char(HIRE_DATE,'YYYY') in ('2011','2012')
AND SALARY BETWEEN 60000 and 100000;

Que14:You would like to display the system date in the format "Monday, 01 June,
2001". Which SELECT statement should you use?
Ans:3) SELECT TO_CHAR(SYSDATE, 'Day, DD Month, YYYY') FROM dual;

Que15:Which is not a valid difference between DELETE and TRUNCATE?


And:
3) DELETE can not be rolled back.
TRUNCATE can be rolled back.

Que16:Git defined as -
4) Distributed Version Control

Que 17:'AS' clause is used in SQL for


3) assigning alternative name for a column
Que18:Find below the structure of Employees table
Employees(Employee_Id,Emp_name,Job_id,Mgrid,Dept_id,sal)

On the EMPLOYEES table, EMPLOYEE_ID is the primary key. MGR_ID is the ID of


managers and refers to the EMPLOYEE_ID. The JOB_ID column is a NOT NULL
column.
Evaluate this DELETE statement:

DELETE employee_id, salary, job_id


FROM employees
WHERE dept_id = 90;

Why does the DELETE statement fail when you execute it?
3) User cannot specify column names in the DELETE clause of the DELETE statement

Que19:State True or False for following Statements :-


A] Files or directory specified in .gitignore file are not tracked
B] .gitignore file is by default available in working directory
C] .gitignore file needs to be tracked
2) A] True
B] False
C] True

Que20:A college staff can borrow up to 5 books from library, which of the following
models represent the case best?

1) A
2) B
3) C
4) D

Que21:Employee's joining date is saved in Emp table's JoiningDate column. Write a


query to find name(s) of the seniormost employee in the company.
1) SELECT Name FROM Emp WHERE JoiningDate = (SELECT JoiningDate FROM Emp)
2) SELECT Name FROM Emp WHERE JoiningDate = (SELECT MAX(JoiningDate ) FROM Emp)
3) SELECT Name FROM Emp WHERE JoiningDate = (SELECT MIN(JoiningDate ) FROM Emp)
4) SELECT Name FROM Emp GROUP BY JoiningDate, Name HAVING JoiningDate=(SELECT
MAX(JoiningDate ) FROM Emp)
5) SELECT Name FROM Emp GROUP BY JoiningDate, Name WHERE JoiningDate = (SELECT
MIN(JoiningDate ) FROM Emp)
Que22:In ORACLE, Which of the following statement is true in case of ORDER BY
clause?
Ans: 1) Null values are displayed last in case of Order by Ascending and at the start in case of
Descending Order.

Que23:In a given class model, which one of the following statement is true?

1) Parent can access attr13


2) Outer can access attr4
3) Child can access attr1
4) None of the above

Que24:You want to display the titles of books that meet following criteria:
1. Purchased before January 21, 2001
2. Price is less then 500 or greater than 900
You want to sort the results by their date of purchase, starting with the most
recently bought book. Which statement should you use?
Ans:4) SELECT book_title FROM books WHERE (price < 500 OR price > 900) AND
purchase_date < '21-JAN-2001' ORDER BY purchase_date DESC;

Que25:For protecting the client classes from changes in attributes and getting
control over state of the object, which one of the following strategies helps best?
Ans:2) Make all attributes private

Que26:In this class model which one of the following OO principles is clearly
violated?

Ans: 3) Encapsulation

Que 27:'AS' clause is used in SQL for


Ans: 3) assigning alternative name for a column

Que28:Which one of the following statements describes "Encapsulation"?


1) All the attributes and methods of every class need to be private.
2) All the attributes and operations of every class need to be public
3) All the data for an application should be in one class and all the operations for application
should be collected in another class. In general class should either contain attributes or
operations but not both.
4) The methods and the data (attributes) on which they operate needs to be kept together in one
class.
Que29:________ can reduce disk I/O by using a rapid path access method to locate
data quickly.
1) INDEX

Que30:Which command creates a local git repository?


Ans:2) git init

Que31:Which query should be used to find all the courses taught in both the 'Fall
2013' semester and in the 'Spring 2014' semester .
1) Select distinct courseid
from section
where semester = 'Fall' and year= 2013 and
courseid not in (select courseid
from section
where semester = 'Spring' and year= 2014);
2) Select distinct courseid
from section
where semester in ('Fall', 'Spring') and year in (2013,2014);
3) Select distinct courseid
from section
where semester = 'Fall' and year= 2013 and
courseid in (select courseid
from section
where semester = 'Spring' and year= 2014);
4) Select distinct courseid
from section
where semester in ('Fall', 'Spring') or year in (2013,2014);
5) None of the above

Que32:Which query should be used to find all the courses taught in both the 'Fall
2013' semester and in the 'Spring 2014' semester .
1) Select distinct courseid
from section
where semester = 'Fall' and year= 2013 and
courseid not in (select courseid
from section
where semester = 'Spring' and year= 2014);
2) Select distinct courseid
from section
where semester in ('Fall', 'Spring') and year in (2013,2014);
3) Select distinct courseid
from section
where semester = 'Fall' and year= 2013 and
courseid in (select courseid
from section
where semester = 'Spring' and year= 2014);
4) Select distinct courseid
from section
where semester in ('Fall', 'Spring') or year in (2013,2014);
5) None of the above

Que33:InGIt, the user configurations on OS level can be modified by using:


1) git config --global
2) git config --userdetails
3) git config --user
4) git config --system

Que34:For protecting the client classes from changes in attributes and getting
control over state of the object, which one of the following strategies helps best?
Ans: 2) Make all attributes private

Que35:State TRUE or FALSE.


One table can contain only one Primary key but multiple foreign keys.
Ans:1) TRUE

Que 36: A college staff can borrow up to 5 books from library, which of the following
models represent the case best?
1) A
2) B
3) C
4) D

Que37:You would like to display the system date in the format "Monday, 01 June,
2001". Which SELECT statement should you use?
Ans:3) SELECT TO_CHAR(SYSDATE, 'Day, DD Month, YYYY') FROM dual;

Que 38:Employee table contains the below data


Employee_id salary department_id
------------------------------------------------------
1 10000 10
2 20000 20
3 35000 null

User executes the below query

select Employee_id, salary,department_id,


NVL2(department_id, salary+1000, salary+2000) "Updated salary"
from Employee;
What will be the value for "Updated salary" column for Employee id 3.
1) 36000
2) 35000
3) 37000
4) 21000
Que 39: You want to display the titles of books that meet following criteria:
1. Purchased before January 21, 2001
2. Price is less then 500 or greater than 900
You want to sort the results by their date of purchase, starting with the most
recently bought book. Which statement should you use?
1) SELECT book_title FROM books WHERE price BETWEEN 500 AND 900 AND
purchase_date< '21-JAN-2001' ORDER BY purchase_date;
2) SELECT book_title FROM books WHERE price IN (500,900) AND purchase_date< '21-JAN-
2001' ORDER BY purchase_date ASC;
3) SELECT book_title FROM books WHERE price < 500 OR > 900 AND purchase_date< '21-
JAN-2001' ORDER BY purchase_date DESC;
4) SELECT book_title FROM books WHERE (price < 500 OR price > 900) AND purchase_date <
'21-JAN-2001' ORDER BY purchase_date DESC;

Que40:State True or False for following Statements :-


A] Files or directory specified in .gitignore file are not tracked
B] .gitignore file is by default available in working directory
C] .gitignore file needs to be tracked
2) A] True
B] False
C] True

Que41:State True or False:-

Merging means to take all your work from other branch to main branch.
1) FALSE
2) TRUE
Que42:The class model of Formatter in the figure demonstrates which Object
Oriented principle(s)

1) Method Overloading
2) Data/Information hiding
3) Method Overriding
4) All of the above

Que43:What are valid constraint types? (Choose Multiples)


1) NOT NULL
2) UNIQUE
3) CANDIDATE KEY
4) PRIMARY KEY
5) CHECK

Que44:What is a Branch in Git?


1) It is just used to classify your work
2) It is to create a new story line to give a try outs on new ideas or bug
3) Branches are used to optimize your code
4) Branches are very complex and heavy weight to deal with

Que45:Find below the structure of Employees table


Employees(Employee_Id,Emp_name,Job_id,Mgrid,Dept_id,sal)

On the EMPLOYEES table, EMPLOYEE_ID is the primary key. MGR_ID is the ID of


managers and refers to the EMPLOYEE_ID. The JOB_ID column is a NOT NULL
column.
Evaluate this DELETE statement:

DELETE employee_id, salary, job_id


FROM employees
WHERE dept_id = 90;

Why does the DELETE statement fail when you execute it?
1) There is no row with dept_id 90 in the EMPLOYEES table.
2) User cannot delete the JOB_ID column because it is a NOT NULL column.
3) User cannot specify column names in the DELETE clause of the DELETE statement
4) User cannot delete the EMPLOYEE_ID column because it is the primary key of the table.

Que46: In UML how is class represented?


Ans: 3) Rectangle with 3 partitions

Que47: Examine the description of the STUDENTS table:

STD_ID NUMBER(4)
COURSE_ID VARCHAR2(10)
START_DATE DATE
END_DATE DATE

Which aggregate functions are valid on the START_DATE column?


1) MIN
2) COUNT
5) MAX

Que48: The EMP table has these columns:


ENAME VARCHAR2(35)
SALARY NUMBER(8,2)
HIRE_DATE DATE
Management wants a list of names of employees who are hired in 2011 or 2012 and
whose salary in the range of 60000 to 100000. Which SQL statement displays the
required results?
1) SELECT ENAME
FROM EMP
WHERE to_char(HIRE_DATE,'YYYY') like '2011' OR '2012'
AND SALARY BETWEEN (60000,100000);
2) SELECT ENAME
FROM EMP
WHERE YYYY(HIRE_DATE) in ('2011','2012')
AND SALARY IN 60000 and 100000;
3) SELECT ENAME
FROM EMP
WHERE to_char(HIRE_DATE,'YYYY') in ('2011','2012')
AND SALARY BETWEEN 60000 and 100000;
4) SELECT ENAME
FROM EMP
WHERE to_date(HIRE_DATE,'YYYY') in ('2011','2012')
AND SALARY BETWEEN 60000 and 100000;

Que49:Which one of the following aspect is NOT covered in class model?


1) Which are abstract classes
2) Which methods are overridden in child class
3) Which class can invoke operation of which other class?
4) When specific operation was invoked by other class

Que50: For writing a robust code, which of the following guidelines need to be
followed
Ans: 3) every attribute of class must be private. For information hiding

Que51: Which one of the following statements describes Encapsulation best?


Ans:2) The class should hide it's private state and behavior and provide a set of business
methods for the manipulation of the the object state.

Que52:Select the correct statements from following:-


Ans:
2) Pull is just a way to get up to date than using fetch
3) The pull command is combination of a fetch from the remote server and a merge of the
changes
4) Good practice is to pull the changes first and then push on the remote

Que53: Database management systems are intended to


Ans: 5) all of the above

Que54: If we are modelling classes Vehicle, Car [rtoNumber] and


Scooter[rtoNumber]. Which of the following is an appropriate way to model the
relationships between them?
Ans: 3) Class Vehicle is a base class with rtoNum as attribute and class car and Scooter are
derived classes.
Que55: Following command is used to:-
git checkout -b<sha>
Ans:3) Recover the deleted branch

Que56: Which of the following is the incorrect statement about GIT?


Ans:3) Multiple developers can not checkout

Que57: Class "Car" inherits from class "Vehicle". Both the classes have method
implementation for start(). Which one of the following OO principles are
demonstrated here?
1) Method overriding
2) Method overloading
3) Reification
4) None of the above

Que 58: Which is not a valid difference between DELETE and TRUNCATE?
Ans:
3) DELETE can not be rolled back.
TRUNCATE can be rolled back.

Que59: Specify some of the critical scenarios that can create merge conflicts.
(Choose most correct 2 options)
1) A developer edits a file and another developer deletes the edited file
3) Different changes being made on same line to the same file

Que60: Which type of variables are associated with class and not the object
4) Static

Que61.Git defined as -
1) Version control for single user
2) Centralized Version Control
3) Not a Directory Content Management System
4) Distributed Version Control

Que62 :What is the output of below?

select trunc(mod(mod(358, 10), 3), 1) from dual;

Note: use truncate if required as per db.


Ans:3) 2

Que63: Employee's joining date is saved in Emp table's JoiningDate column. Write a
query to find name(s) of the seniormost employee in the company.
Ans:3) SELECT Name FROM Emp WHERE JoiningDate = (SELECT MIN(JoiningDate ) FROM
Emp)

Que 64 In DML statements, which type of Variables are used to prompt user to enter
values atRun time?
Ans:2) Substitution variables

Que 65: Student registers for 4 subjects for university exam.


Which of the following relationship represents it best?

Ans:1) A

QUE 65: Which of the following is correct command to merge idea branch to master?

Ans: 1)git merge idea

que 66: User A would like to insert a row into the EMPLOYEE table that has three columns: EMPID, LASTNAME, and SALARY.
The user would like to
enter data for EMPID 59694 and LASTNAME Harris, but no salary. Which statement would work?
1) insert into EMPLOYEE
values (59694,'HARRIS', NULL);

QUE 67: Which one of the following relationship is mandatory for method overloading
4) None of the above
Que68: "IS-A" or "IS KIND OF" relationship can be best represented by which one of the following relationships?
Ans:4) Inheritance

QUE 68: Select the correct mapping:


i. CREATE - DDL
ii. RENAME - DCL
iii. ROLLBACK - TCL
iv. REVOKE - DCL
v. DELETE - DDL
vi. UPDATE - DML
1) i, iii, iv, vi

QUE 69 _______ can reduce disk I/O by using a rapid path access method to locate data quickly.

1) INDEX
2) PRIMARY KEY
3) UNIQUE constraint
4) SEQUENCE

QUE69: Which of the following are correct basic steps to work with Git Remote?
4) Setup a GitHub Account
Create Repository
Add Remote
Push Changes to Remote(Push)
Check Changes in Remote(Fetch)
Merge in Fetched Changes(Merge)

QUE 70: WHich of the following activities represent Abstraction in Object Orientation?
1) Identifying correct abstract class
2) Creating class with all abstract methods
3) Ignoring inessential details
4) Convert concrete class in to pure abstract class

QUE 71 State TRUE or FALSE.


< ALL operator means less than minimum and > ALL operator means greater than Maximum.
1) TRUE

QUE 72 method travel(src: string, dest: string) in a base class and travel(dest: string) in derived class is a best example of ...
Ans:2) Overloading

QUE 73 For protecting the client classes from changes in attributes and getting control over state of the object, which one of
the following strategies helps best?
Ans:
2) Make all attributes private

QUE74 Choose the correct sequence of command from following to track a file.
(Assume file is being tracked for first time)
2) git init
git add <filename.extension>
git commit -m <message>

QUE75 : Select the correct option with regards to Stag


ing Area?
Ans: 2) Marking a modified file in its current version to go into your next commit snapshot

QUE 76 To delete remote branch what is the command that is used?


1) git push <remote_name> --delete <branch name>

QUE 77 ___ is not a Transaction control language statement


Ans: Revoke

QUE 78 Which of the following command(s) can be used to integrate changes from one branch to another branch ?
Ans: 2) git rebase

QUE 79: To remove and discard the changes from the last commit on your current branch, you should use:
2) git reset --hard HEAD~1

QUE 80 In a real world, "House" may have large number of (possible) features, but while considering for software application
development, we consider only features of "House", which are relevant to the software. What is a formal term for this is
Object Oriented field?
3) Abstraction

QUE 81 One table can contain only one Primary key but multiple foreign keys.

1) TRUE

Que 82 Which of the following command is used to configure a user name as 'abc'?
1) git config --global user.name "abc"

Que 83 Choose the correct syntax for renaming the file.


Ans:2) git mv <source><destination>

Que84: Git is less preferred for handling extremely large files or frequently changing binary files while SVN can handle
multiple projects stored in the same repository.
Ans:1) TRUE

Que 85: Which one of the following statements is true?


1) We can not overload a method in same class
2) We can not override a method in same class
3) Overloaded methods have exactly same method signature.
4) None of the above statements is true

Que 86 :___ clause filters the Summarized data.


Ans:4) HAVING

Que 87 Which SQL statement accepts user input for the columns to be displayed, the table name, and WHERE condition?
Ans:
3) SELECT &1, &2
FROM &3
WHERE last_name = '&4';

Que 88 Column in a table refers to ___________ in Entity Relationship diagram.


3) Attribute

Que 89: What will be the output of


select initcap(substr('Checklist',6)) from dual;
2) List
Que 90:Which one of the following statements is correct for Inheritance relationship?
Ans: 2) Derived class inherits the properties of base class

Que: 91:Subquery can be used in


a. FROM clause of SELECT statement
b. WHERE clause of SELECT statement
c. GROUP BY clause of SELECT statement
d. SET clause of UPDATE statement
e. WHERE clause of DELETE statement
f. ORDER BY clause of SELECT statement

Ans:a,b,d,e

Que 92: What is Tag in git? select appropriate options from following.
Ans:
1) Tag is just like a label
4) Tag is to mark a stable release points

Que 93: SELECT ROUND(5.693893) from dual;


Ans:3) Returns 6

Que 94: The EMP table has these columns:


ENAME VARCHAR2(35)
SALARY NUMBER(8,2)
HIRE_DATE DATE
Management wants a list of names of employees who are hired in 2011 or 2012 and whose salary in
t
Ans:3) SELECT ENAME
FROM EMP
WHERE to_char(HIRE_DATE,'YYYY') in ('2011','2012')
AND SALARY BETWEEN 60000 and 100000;

Que 95: Which command will automatically commit a new change to your local repository that
does the opposite changes of a previous commit, effectively eliminating a previous commit chnage
from repository?
Ans:Revert

Que 96: Which one of the class models in figure, represent good abstraction of a Car for driver?
Ans:2) B

Que 97: State True or False :-


Git add command just adds files to staging area and doesn't actually commits.
Ans:1) TRUE

Que 98: A primary key is combined with a foreign key creates


Ans:1) Parent-Child relationship between the tables that connect them.

Que 99: Match the following :-


A] git status A] Operates on committed history
B] git log B] Operates on staging area and repository
C] git diff --staged C] Inspects working directory and staging area

Ans:1) A -> C
B -> A
C -> B

Que 100: Which one of the following statements is true?


Ans:2) We can not override a method in same class

Que 101: Benefits of adding a remote are:-


Ans:1) work collaboration
2) Data Back up
3) Central clearing house

Que 102: Select the essential benefits given by Branching. (Choose most correct 2 options)
Ans:
2) Helps merge changes in teams and resolve conflicts
3) Helps work and push changes without impacting the teams involved

Que 103: Which of the below statements are True for object Index?
Ans:
1) It can speed up the retrieval of rows by using a pointer.
2) Indexes can be created explicitly or automatically.
3) If you do not have an index on the column, then a full table scan occurs.

Que 104: Polymorphism means


Ans:4) an operation with different possible implementations

Que 105: Database management systems are intended to


Ans:5) all of the above

Que 106 : Which statement describes a commit in Git?


Ans:2) The changes to the project sources since the previous commit

Que 107:_ _ is not a Transaction control language statement


Ans:1) Revoke

Que 108 Select the correct mapping:


i. CREATE – DDL
ii. RENAME - DCL
iii. ROLLBACK - TCL
iv. REVOKE - DCL
v. DELETE - DDL
vi. UPDATE – DML
Ans:3) i, iii, iv, vi

Que 109: Which of the following is correct command to delete a branch


Ans:4) git branch -d 'branch_name'

Que 110: For protecting the client classes from changes in attributes and getting control over state
of the object.
Ans:2) Make all attributes private

Que 111: WHich of the following activities represent Abstraction in Object Orientation?
Ans:3) Ignoring inessential details

Que 112: State True or False for following statements:-


A] git reset permanently removes commits from repository.
B] git revert is to undo any commit message.
C] git checkout is to undo the committed changes.
Ans:3) A] True
B] True
C] False

Que 113: State True or False:- If you want to preserve the complete history of your project and
avoid the risk of
Ans:2) FALSE

Que 114 : Which one of the following aspect is NOT covered in class model?
Ans:4) When specific operation was invoked by other class

Que 115: Which of the following commands can we use to create a branch in an existing repository?
Ans:2) git branch<branch name>
4) git checkout -b<branch name>

Que 116: By default, git stash pop will re-apply the most recently added stash.
Ans:1) TRUE

Que 117: Which is not a valid difference between DELETE and TRUNCATE?
Ans:
3) DELETE can not be rolled back.
TRUNCATE can be rolled back.

Que 118: Which all are the correct statements with regards to branching in git?
A] Branching is used for code optimization.
B] Branching helps to solve a bug.
C] Branching is to try out new feature.
Ans: A] False
B] True
C] True

Que 119: Which one of the following relationship is mandatory for method overloading.
Ans:4) None of the above

Que 120: ___________ and ___________ operators combines the result of two component
conditions to produce a si
Ans:1) AND
5) OR
Que 121: Which command is used to check last 5 commits by a particular author?
Ans:4) git log -n 5 --author=<"pattern">

Que 122: Which of the below can be used to verify that the password entered by the user matches
a certain strength
Ans:2) Check constraint

Que 123:State True or false.


Synonyms can be created for database objects owned by other users for which you have access.
Ans:1) TRUE

Que 124 :Select the correct option with regards to Staging Area?
Ans:4) Marking a modified file in its current version to go into your next commit snapshot

Que 125: If the methods in class Admin are accessing the data of class Employee, which one of
these OO principlesis primarily violated?
Ans:4) Encapsulation

Que 126 :What is the output of below?


select trunc(mod(mod(358, 10), 3), 1) from dual;
Note: use truncate if required as per db.
Ans:3) 2

Que 127: Which one of the following ways helps in data/ information hiding?
Ans: 3) making attributes of a class private

Que 128: A person has many attributes possible like (name, email, mobile number, weight, height,
eye color and so on ...). But while considering class Employee (i.e.)Person working for IT company,
model can ignore inessential attributes like weight, height, eye color etc. Which one of the following
principles is demonstrated here?
Ans: Abstraction

Que 129 : git diff --cached': Shows differences between :-


Ans: Index and the most recent commit

Que 130: . Which DDL statement can be used to remove rows from table t1?
Ans: Truncate
Que 131: . What is the outcome of the query?
SELECT * FROM payments
Where amount=(SELECT MAX(amount)
FROM payments)
AND sales_person_id in (SELECT sales_person_id
FROM salesman Where office_code='PUNE')
Ans: Details of the highest payment which is taken by a sales person whose office is Pune

Que 132: Which one of the relationships can exist between classes "Clock" and "DigitalClock"?
Ans: Inheritance.

Que 133:. Which one of the following relationship is essential for run time polymorphism?
Ans: Inheritance.

Que 134:. if class "Department" contains, methods countProfessors() and countProfessors(criteria:


int). Which OO principle it demonstrates
Ans: Method overloading.

QUE 135: In below example, what would be the value of NEXTVAL after 1000 numbers.

CREATE SEQUENCE seq1

START WITH 1

INCREMENT BY 1

MAXVALUE 1000

NOCYCLE;

1) 1

2) 0

3) 1001

4) Call to Nextval will throw the error.

Ans-4

QUE136: Select the correct option with regards to Staging Area?

1) Marking a new file to make it ready to edit

2) Marking a new file to remove from repository

3) Committing a file to repository

4) Marking a modified file in its current version to go into your next commit snapshot
QUE 137: A primary key is combined with a foreign key creates

1) Parent-Child relationship between the tables that connect them.

2) Many to many relationship between the tables that connect them.

3) Network model between the tables that connect them.

4) None of these

QUE 138 : ___________ and ___________ operators combines the result of two component
conditions to produce a single result based on them.

1) AND

4) OR

Ans-1,4

QUE 139: Consider the below table structure

Employees(Employee_id,Last_name,job_id,salary,commission_pct,Department_id)

Departments(department_id,department_name)

Which is the correct query to delete all the employees from Employees table who are in a
department where the department name contains the string 'Public.'

ANS--3) DELETE FROM employees

WHERE department_id =

(SELECT department_id

FROM departments

WHERE department_name LIKE '%Public%');

QUE 140: You want to change the name of file1 to file2 in Git. What command accomplishes this?

1) git ls file1 file2

2) git rm file1 file2

3) git mv file1 file2

4) git rn file1 file2


QUE141: In this class model which one of the following OO principles is clearly violated?

1) Abstraction

2) Data hiding

3) Encapsulation

4) Economy of expression

Ans-3

QUE142: In DML statements, which type of Variables are used to prompt user to enter values at
Run time?

Ans: 2)Substitution variables

QUE 143: Git add command just adds files to staging area and doesn't actually
commits.
1) TRUE
2) FALSE
QUE144: Choose correct options from following while
Adding Remote repository helps us to :-
A] Sync up work with team.

C] Central clearing house.


D] Keep a back up.
4) A,C,D\

QUE 145; Which one of the following statements is true?

2) We can not override a method in same class


QUE146 Which is not a valid difference between DELETE and TRUNCATE?
2) DELETE can not be rolled back.
TRUNCATE can be rolled back.

QUE 147: Mr. Natawarlal being businessman has three Cars in his house,
His personal Car
His wife's Car
Company Car
Which of the following is the best way to model this description.
1) "Businessman" class is associated with class "Car". "PersonalCar", "WifesCar" and
"CompanyCar"
are instances of class "Car"
QUE148: In ORACLE, Which of the following statement is true in case of ORDER BY
clause?
1) Null values are displayed last in case of Order by Ascending and at the start in case of
Descending
Order.

Que 149: State True or False for following statements:-


A] git reset permanently removes commits from repository.
B] git revert is to undo any commit message.
C] git checkout is to undo the committed changes.

3) A] True
B] True
C] False

Which of the following is correct command to merge idea branch to master?

3) git merge idea

Que 150: Select the appropriate basic workflow of Git from following.
Ans:

Edit

Stage

Review

Commit

You might also like