Subscribe

RSS Feed (xml)

Powered By

Skin Design:
Free Blogger Skins

Powered by Blogger

search topic

Showing posts with label Oracle Latest Placement Papers. Show all posts
Showing posts with label Oracle Latest Placement Papers. Show all posts

Friday, May 23, 2008

Oracle Placement Paper 2

See Oracle All Recent and Previous Papers 1 to 7

Hints
It contains 30 Questions of SQL + PL/SQL and the TIME allocated is 30 minutes

After test (15 Mins.) a Oracle guy declared test results by announcing the full name of candidates and apologising to others. Very Polite.

Then another test for Programming is there.

After this they have to go for the round of Interviews.

Aptitude section of Oracle

1.Two words are given by
Word 1: 83263641
Word 2: 3715468 ( don?t remember the order of the numbers.)
Each character is represented by a digit and each digit represents a character. It is given that T and R occur four times. S and A occur two times. E, P, O and M occur one time each. The word starts with T. The letter E occurs in word one only. The questions were,
a). Which number represents T.
b). Which number represents S.
c). Which character represents 2.
d). Which digit represents A.
e). Which word represents word 2.

2.There was a table with data related to net sales, gross profit, etc... and some questions were asked related to it. Very easy?

3.A man spent 1/6th of his life in child hood, 1/12th of his life as youngster and 1/7th of his life as a bachelor. After five years of his marriage a son was born to him. The son died four years before the father died and at the time of his death his age was half the total age of his father.
The questions were,
a. What is the age of the father. (84)
b. At what age was he married.(33)
c. What is the age of his son.(42)

4.Rita puts 9 pairs of black socks and 8 pairs of white socks in a drawer. She takes 3 socks. What is the probability that we get a pair of black socks.

5.What is the value of the following series 1/7 + 2/72 + 1/73 +2/74 + 1/75 + ???.

6.What should be the value of a, in the polynomials x2 ? 11x + a and x2 ? 14x + 2a, so that these two polynomials have common factors. a) 24 b)1 c)-1 d)1/2

7.What is the sum of all the four digit numbers formed using the digits 0, 1, 2 and 3. None of the two digits should be repeated.

8.a right angled triangle, the square of the hypotenuse is twice the product of the other two sides. Then one of the acute angles of the triangle is? a) 450 b) 300 c) 600 d) 150

9.There are two square rooms. Both are of same height. The second room is 5m longer than the first room. The rate for papering the walls is 10 paisa per square meter. The total cost for papering the rooms is Rs 60 and Rs 80. What is the height of the rooms.

10.There are two numbers in the ratio 8:9. if the smaller of the two numbers is increased by 12 and the larger number is reduced by 19 thee the ratio of the two numbers is 5:9.
Find the larger number.

11.In class of 10 students, the teacher writes a number on the board. The first student tells that the number is divisible by 1, the second student tells that the number is divisible by 2, the third by 3, the forth by 4 and so on till 10. If the statement of one of the students in wrong then what is the least number possible.

12.The first and the last sentences of a set of sentences are given. The middle four sentences are in jumbled form we have to select the order in which the sentences are to be placed so that they convey a meaningful message.

13.A passage with two paragraphs is given. Then two questions are asked based on it. Could not remember it.

14.A stamp collector arranges his stamps during his free time. When he arranges his stamps in pairs, there is one stamp left. It is the same when he arranges the stamps in groups of 3, 4, 5 and 6. Now, how many stamps will he be left with when he arranges them in groups of 8.
Technical

15.Delete from table tempv where rowid in (select rowid from tempv where rowid in (((select min(rowid) from tempv where ... count(*) > 1))) union(select rowid from tempv where rowid in (((select min(rowid) from tempv where ... count(*) > 1)));

16.When there is a failure in fetching the rows from a cursor...
a. %isopen
b. %notfound
c. %found
d. %rowcount

17.Select 'oracle' from dual where null = null;
a. oracle
b. null
c. error out
d. no rows selected

18.here is a question of Package body and Package Specification, they have provided the code for that describing the scenario of movie_tickets_sold and asked the programmer to insert a block of code...., where that code block to be inserted? In Package body? or in Package Specification?

19.Which of the following operator is not used in Outer Join?
a. =
b. !=
c. AND
d. OR

20.PL/SQL uses which of the following
a. Early Binding
b. Late binding
c. No Binding
d. Deferred Binging

21.Following is a database trigger, CREATE OR REPLACE TRIGGER delete_row ON DELETE
not remember the complete question.

22.If table contains 100 rows and it is truncated, how many rows get updated
a. 0
b. 1
c. 100
d. No rows updated

There are some questions on Basic SELECT STATEMENTS...

Some questions on Triggers, Procedures

VARRAYS/Nesting of Table: 1 question is there

NLS_DATE_FORMAT: 1 question

1.The size of the float data type in C language is ?

2.The size of the float data type in C language is ?
What is the output of the following C program.
Main()
{
printf(?%c?,?abcdefgh?[4]);
}

3.What is the o/p of the following C-program.
Main()
{
char str[7]=?strings?;
printf(?%s?,str);
}

4.main()
{
file *fp;
fp=fopen(?xyz?,?r?);
}
What does fp point to?

5.What is the maximum no. of arguments that can be given in a command line in C.

6.When the variables are pushed into the stack, which method is used to retrieve them from it.
a) pop b) pull c) remove d) none of these.

7.What is the size of integer variable in JAVA?

8.A programs reads ?The man and the boy\r\n? from a file using fgets() and stores it in str[]. Then the string stored in str is
a) ?The man and the boy\r\n\0?
b) ?The man and the boy\r\0?
c) ?The man and the boy\n\0?
d) ?The man and the boy\0?

After this written exam, we had another written for the short-listed students. It contained algorithms and coding. There were two questions.

1.The first one was the conversion of a given expression into its postfix form and then to evaluate it.

2.The question was to have a circularly linked link-list of integers 1 to n. I we give k as an input then we have to output(print) 1, k, 1+2k, 1+3k ? till n and we have to delete these numbers. When we give then next k we have to continue the same process starting with 2. The linked needs to be maintained

See More Latest Oracle Placement Question Papers for campus placements in India and walkin interviews for freshers. See 2007 and 2008 placement paper aptitude, technical, database, programming, dbms, reasoning questions only on previouspapers.blogspot.com

Oracle Recent Placement Paper 3

See Oracle All Recent and Previous Papers 1 to 7

SQL AND SQL*Plus

Which of the following statements contains an error?
a.. SELECT * FROM emp WHERE empid = 493945;
b. SELECT empid FROM emp WHERE empid= 493945;
c. SELECT empid FROM emp;
d. SELECT empid WHERE empid = 56949 AND lastname = 'SMITH';

Which of the following correctly describes how to specify a column alias?
a. Place the alias at the beginning of the statement to describe the table.
b. Place the alias after each column, separated by white space, to describe the column.
c. Place the alias after each column, separated by a comma, to describe the column.
d. Place the alias at the end of the statement to describe the table.

The NVL function
a. Assists in the distribution of output across multiple columns.
b. Allows the user to specify alternate output for non-null column values.
c. Allows the user to specify alternate output for null column values.
d Nullifies the value of the column output

Output from a table called PLAYS with two columns, PLAY_NAME and AUTHOR,is shown below.Which of the following SQL statements produced it?
PLAY_TABLE
"Midsummer Night's Dream", SHAKESPEARE
"Waiting For Godot", BECKETT
"The Glass Menagerie", WILLIAMS

a SELECT play_name author FROM plays;
b SELECT play_name, author FROM plays;
c SELECT play_name', ' author FROM plays;

d SELECT play_name', ' author PLAY_TABLE FROM plays;

Issuing the DEFINE_EDITOR="emacs" will produce which outcome?
a. The emacs editor will become the SQL*Plus default text editor.
b. The emacs editor will start running immediately.
c. The emacs editor will no longer be used by SQL*Plus as the default text editor.
d. The emacs editor will be deleted from the system.

The user issues the following statement. What will be displayed if the EMPID selected is 60494? SELECT DECODE(empid,38475, "Terminated",60494, "LOA", "ACTIVE")FROM emp;
a. 60494
b. LOA
c. Terminatedd. ACTIVE

SELECT (TO_CHAR(NVL(SQRT(59483), "INVALID")) FROM DUAL is a valid SQL statement.
a. TRUE
b. FALSE

The appropriate table to use when performing arithmetic calculations on values defined within the SELECT statement (not pulled from a table column) is
a. EMP
b. The table containing the column values
c. DUALD. An Oracle-defined table

Which of the following is not a group function?
a. avg( )
c. sqrt( )
c. sum( )
d. max( )

Once defined, how long will a variable remain so in SQL*Plus?
a. Until the database is shut down
b. Until the instance is shut down
c. Until the statement completes
d. Until the session completes

The default character for specifying runtime variables in SELECT statements is
a. Ampersand
b. Ellipses
c. Quotation marks
d. Asterisk

A user is setting up a join operation between tables EMP and DEPT. There are some employees in the EMP table that the user wants returned by the query, but the employees are not assigned to departments yet. Which SELECT statement is most appropriate for this user?
a. select e.empid, d.head from emp e, dept d;
b. Select e.empid, d.head from emp e, dept d where e.dept# = d.dept#;
c. Select e.empid, d.head from emp e, dept d where e.dept# = d.dept# (+);
d. Select e.empid, d.head from emp e, dept d where e.dept# (+) = d.dept#;

Developer ANJU executes the following statement: CREATE TABLE animals AS SELECT * fromMASTER.ANIMALS; What is the effect of this statement?
a. A table named ANIMALS will be created in the MASTER schema with the same data as the ANIMALS table owned by ANJU
b. A table named ANJU will be created in the ANIMALS schema with the same data as the ANIMALS table owned by MASTER
c. A table named ANIMALS will be created in the ANJU schema with the same data as the ANIMALS table owned by MASTER.
d. A table named MASTER will be created in the ANIMALS schema with the same data as the ANJU table owned by ANIMALS.

User JANKO would like to insert a row into the EMPLOYEE table, which has three columns: EMPID,LASTNAME, and SALARY. The user would like to enter data for EMPID 59694, LASTNAME Harris, but no salary. Which statement would work best?
a. INSERT INTO employee VALUES (59694,'HARRIS', NULL);
b. INSERT INTO employee VALUES (59694,'HARRIS');
c. INSERT INTO employee (EMPID, LASTNAME, SALARY) VALUES (59694,'HARRIS');
d. INSERT INTO employee (SELECT 59694 FROM 'HARRIS');

Which three of the following are valid database datatypes in Oracle? (Choose three.)
a. CHAR
b. VARCHAR2
c. BOOLEAN
d. NUMBER

Omitting the WHERE clause from a DELETE statement has which of the following effects?
a. The delete statement will fail because there are no records to delete.
b. The delete statement will prompt the user to enter criteria for the deletion
c. The delete statement will fail because of syntax error.
d. The delete statement will remove all records from the table.

Creating a foreign-key constraint between columns of two tables defined with two different datatypes will produce an error.
a. TRUE
b. FALSE

Dropping a table has which of the following effects on a nonunique index created for the table?
a. No effect.
b. The index will be dropped.
c. The index will be rendered invalid.
d. The index will contain NULL values.

To increase the number of nullable columns for a table,
a. Use the alter table statement.
b. Ensure that all column values are NULL for all rows.
c. First increase the size of adjacent column datatypes, then add the column.
d. Add the column, populate the column, then add the NOT NULL constraint.

Which line of the following statement will produce an error?
a. CREATE TABLE goods
b. (good_no NUMBER,
c. good_name VARCHAR2 check(good_name in (SELECT name FROM avail_goods)),
d. CONSTRAINT pk_goods_01
e. PRIMARY KEY (goodno));
f. There are no errors in this statement.

MAXVALUE is a valid parameter for sequence creation.
a. TRUE
b. FALSE

Which of the following lines in the SELECT statement below contain an error?
a SELECT DECODE(empid, 58385, "INACTIVE", "ACTIVE") empid
b. FROM emp
c. WHERE SUBSTR(lastname,1,1) > TO_NUMBER('S')
d. AND empid > 02000
e. ORDER BY empid DESC, lastname ASC;
f. There are no errors in this statement.

Which function below can best be categorized as similar in function to an IF-THEN-ELSE statement?
a. SQRT
b. DECODE
c. NEW_TIME
d. ROWIDTOCHAR

Which two of the following orders are used in ORDER BY clauses? (choose two)
a. ABS
b. ASC
c. DESC
d. DISC

You query the database with this command SELECT name FROM employee WHERE name LIKE ?_a%?; Which names are displayed?
a. Names starting with ?a?
b. Names starting with ?a? or ?A?
c. Names containing ?a? as second character
d. Names containing ?a? as any letter except the firs

PL/SQL

Which of the following statements is true about implicit cursors?
a. Implicit cursors are used for SQL statements that are not named.
b. Developers should use implicit cursors with great care.
c. Implicit cursors are used in cursor for loops to handle data processing.
d. Implicit cursors are no longer a feature in Oracle.

Which of the following is not a feature of a cursor FOR loop?
a. Record type declaration.
b. Opening and parsing of SQL statements.
c. Fetches records from cursor.
d. Requires exit condition to be defined.

A developer would like to use referential datatype declaration on a variable. The variable name is EMPLOYEE_LASTNAME, and the corresponding table and column is EMPLOYEE, and LNAME, respectively. How would the developer define this variable using referential datatypes?
a. Use employee.lname%type.
b. Use employee.lname%rowtype.
c. Look up datatype for EMPLOYEE column on LASTNAME table and use that.
d. Declare it to be type LONG.

Which three of the following are implicit cursor attributes?
a. %found
b. %too_many_rows
c. %notfound
d. %rowcount
e. %rowtype

If left out, which of the following would cause an infinite loop to occur in a simple loop?
a. LOOP
b. END LOOP
c. IF-THEN
d. EXIT

Which line in the following statement will produce an error?
a. cursor action_cursor is
b. select name, rate, action
c. into action_record
d. from action_table;
e. There are no errors in this statement.

The command used to open a CURSOR FOR loop is
a. open
b. fetch
c. parse
d. None, cursor for loops handle cursor opening implicitly

What happens when rows are found using a FETCH statement
a. It causes the cursor to close
b. It causes the cursor to open
c. It loads the current row values into variables
d. It creates the variables to hold the current row values

CREATE OR REPLACE PROCEDURE find_cpt (v_movie_id {ArgumentMode}NUMBER, v_cost_per_ticket {argument mode} NUMBER)IS
BEGIN
IF v_cost_per_ticket > 8.5 THEN
SELECT cost_per_ticket
INTO v_cost_per_ticket
FROM gross_receipt
WHERE movie_id = v_movie_id;
END IF;
END;
Which mode should be used for V_COST_PER_TICKET?
a. IN
b. OUT
c. RETURN
d. IN OUT

CREATE OR REPLACE TRIGGER update_show_gross {trigger information}
BEGIN
{additional code}
END;
The trigger code should only execute when the column, COST_PER_TICKET, is greater than $3.75. Which trigger information will you add?
a. WHEN (new.cost_per_ticket > 3.75)
b. WHEN (:new.cost_per_ticket > 3.75
c. WHERE (new.cost_per_ticket > 3.75)
d. WHERE (:new.cost_per_ticket > 3.75)

What is the maximum number of handlers processed before the PL/SQL block is exited when an
exception occurs?
a. Only one
b. All that apply
c. All referenced
d. None

For which trigger timing can you reference the NEW and OLD qualifiers?
a. Statement and Row
b. Statement only
c. Row only
d. Oracle Forms trigger

CREATE OR REPLACE FUNCTION get_budget(v_studio_id IN NUMBER) RETURN number
ISv_yearly_budget NUMBER;
BEGIN
SELECT yearly_budget
INTO v_yearly_budget
FROM studio
WHERE id = v_studio_id;
RETURN v_yearly_budget;
END;
Which set of statements will successfully invoke this function within SQL*Plus?
a VARIABLE g_yearly_budget NUMBER EXECUTE g_yearly_budget := GET_BUDGET(11);
b. VARIABLE g_yearly_budget NUMBER EXECUTE :g_yearly_budget := GET_BUDGET(11);
c. VARIABLE :g_yearly_budget NUMBER EXECUTE :g_yearly_budget := GET_BUDGET(11);
d. VARIABLE g_yearly_budget NUMBER :g_yearly_budget := GET_BUDGET(11);

CREATE OR REPLACE PROCEDURE update_theater (v_name IN VARCHAR2, v_theater_id IN NUMBER) IS
BEGIN
UPDATE theater
SET name = v_name
WHERE id = v_theater_id;
END update_theater;
When invoking this procedure, you encounter the error: ORA-00001: Unique constraint (SCOTT.THEATER_NAME_UK) violated.How should you modify the function to handle this error?
a. An user defined exception must be declared and associated with the error code and handled in the EXCEPTION
section.
b. Handle the error in EXCEPTION section by referencing the error code directly.
c. Handle the error in the EXCEPTION section by referencing the UNIQUE_ERROR predefined exception.
d. Check for success by checking the value of SQL%FOUND immediately after the UPDAT statement.

CREATE OR REPLACE PROCEDURE calculate_budget IS v_budget studio.yearly_budget%TYPE;
BEGIN
v_budget := get_budget(11);
IF v_budget < yearly_budget =" v_new_budget" id =" v_studio_id;">

Oracle Latest Sample Question Paper - 4

See Oracle All Recent and Previous Papers 1 to 7
This is the oracle paper held on July 13 2003 at NITK Surathkal. The test has 2 sections : 30 technical and 30 aptitude and 60 min time. Technical section: its very easy any one can answer 25 qns without preperation. some are

How compiler treats variables of recursive functions

What is orthogonal matrix?

Given two tables and asked 2 qns on those table ,

One is on join and another is on NOT IN

Given some qns on pointers( pretty easy)

Given five qns on data structures like , lifo, fifo

Qtn on primary key

How NULL in sql is treated?

Given a doubly linked list and asked r->left->right->data ans: r->data

Explain const char *ptr and char *const ptr

Remaining i didn`t remember

Technical
What is the output of the following program?
( Sorry Not available )

Oracle Latest Detailed Placement Paper 5

See Oracle All Recent and Previous Papers 1 to 7

Campus Interview Conducted in Surathkal on 11th July -2003

Test was of 1 hour 30 questions. g aptitude and 30 of technical.......some questions. of aptitude
were very lengthy so don't end up in solving them.....time was less......some 15 questions. from
arithmetic......and rest 15 logical,statement interpretation,arrangement,tense correction......and
like that......

Given a square matrix which consists only of 1 and 0......find which rows,which cols and which diagonals consist entirely of 1's.

Given an array of integers find all possible combinations of the numbers whose sum equal to 90.....
ans : knapsack problem (in data structures - aho ullman)

Note : for them solution was not the criteria.......but the approach was important......the solution
should be generalised and optimized........optimization was given the top priority........

Technical Papers

const int MAX=10;
main()
{
enum a {a,b,MAX};
print MAX;
}
ans. 2

enum variable is a const variable which can only be assigned a value at initialization or a non const variable which can be assigned any value in the middle of the program?
ans. const variable

void *p; what operation cannot be performed on p? ans : arithmetic operation unless it is properly typecasted

char **p="Hello";
print p,*p,**p
ans. Hello (null)
warning: suspicious pointer conversion

main()
{
char str[]="Geneius";
print (str);
}
print(char *s)
{
if(*s)
print(++s);
printf("%c",*s);
}
ans. suiene

what does the function fcloseall() does ?
ans. fcloseall() closes all open streams except stdin,stdout,stderr,stdprn and stdaux

main()
{
printf("Genius %d",fun(123));
}
fun(int n)
{
return (printf("%d",n));
}
ans. 123genius3

difference between definition and declaration. ans. definition once while declaration more than once

find the error?
main()
{
void fun();
fun();
}
void fun()
{
int i=10;
if(i<10) a="9,b=" c="3,d;" d="(b-c)<(c-a)" 1="?" i="4;" i="i/4);" cols="?" size="5">Special: How the year passes away? Can u imagine a question related to this? January - Jan, February - Feb, March, April, May, June, July, August - Aug, September - Sep, October - Oct, November - Nov, December - Dec. Keep your eyes open, remember and think deeply. There are many riddles, puzzles and other questions in placement Interview related to THESEa

Oracle Placement Paper and tech round - 6

Oracle DBA Questions
See Oracle All Recent and Previous Papers 1 to 7
SNAPSHOT is used for [DBA]
a. Synonym, b. Table space, c System server, d Dynamic data replication Ans : D

We can create SNAPSHOTLOG for[DBA]
a. Simple snapshots, b. Complex snapshots, c. Both A & B, d Neither A nor B Ans : A

Transactions per rollback segment is derived from[DBA]
a. Db_Block_Buffers, b. Processes, c. Shared_Pool_Size, d. None of the above
Ans : B

ENQUEUE resources parameter information is derived from[DBA]
a. Processes or DDL_LOCKS and DML_LOCKS, b. LOG_BUFFER, c. DB__BLOCK_SIZE..
Ans : A

LGWR process writes information into
a Database files, b Control files, c Redolog files, d All the above. Ans : C

SET TRANSACTION USE ROLLBACK SEGMENT is used to create user objects in a particular Tablespace
a True, b False Ans : False

Databases overall structure is maintained in a file called
a Redolog file, b Data file, c Control file, d All of the above.
Ans : C

These following parameters are optional in init.ora parameter file DB_BLOCK_SIZE, PROCESSES
a True, b False Ans : False

Constraints cannot be exported through EXPORT command
a True, b False Ans : False

It is very difficult to grant and manage common privileges needed by different groups of database users using the roles
a True, b False Ans : False

What is difference between a DIALOG WINDOW and a DOCUMENT WINDOW regarding moving the window with respect to the application window
a Both windows behave the same way as far as moving the window is concerned.
b A document window can be moved outside the application window while a dialog window cannot be moved
c A dialog window can be moved outside the application window while a document window cannot be moved
Ans : C

What is the difference between a MESSAGEBOX and an ALERT

A messagebox can be used only by the system and cannot be used in user application while an alert can be used in user application also.

A alert can be used only by the system and cannot be use din user application while an messagebox can be used in user application also.

An alert requires an response from the userwhile a messagebox just flashes a message
and only requires an acknowledment from the user

An message box requires an response from the userwhile a alert just flashes a message an only
requires an acknowledment from the user Ans : C

Which of the following is not an reason for the fact that most of the processing is done at the server ?
a To reduce network traffic. b For application sharing, c To implement business rules centrally,
d None of the above
Ans : D

Can a DIALOG WINDOW have scroll bar attached to it ?
a Yes, b No Ans : B

Which of the following is not an advantage of GUI systems ?
a. Intuitive and easy to use., b. GUI's can display multiple applications in multiple windows
c. GUI's provide more user interface objects for a developer d. None of the above
Ans :D

What is the difference between a LIST BOX and a COMBO BOX ?
a In the list box, the user is restricted to selecting a value from a list but in a combo box the user can type in value which is not in the list
b A list box is a data entry area while a combo box can be used only for control purposes
c In a combo box, the user is restricted to selecting a value from a list but in a list box the
user can type in a value which is not in the list
d None of the above
Ans : A

In a CLIENT/SERVER environment , which of the following would not be done at the client ?
a User interface part, b Data validation at entry line, c Responding to user events,
d None of the above Ans : D

Why is it better to use an INTEGRITY CONSTRAINT to validate data in a table than to use a STORED
PROCEDURE ?
a Because an integrity constraint is automatically checked while data is inserted into or updated in a table while a stored procedure has to be specifically invoked
b Because the stored procedure occupies more space in the database than a integrity constraint definition
c Because a stored procedure creates more network traffic than a integrity constraint definition
Ans : A

Which of the following is not an advantage of a client/server model ?
a. A client/server model allows centralised control of data and centralised implementation of business rules.
b A client/server model increases developer;s productivity
c A client/server model is suitable for all applications
d None of the above.
Ans : C

What does DLL stands for ?
a Dynamic Language Library
b Dynamic Link Library
c Dynamic Load Library
d None of the above
Ans : B

POST-BLOCK trigger is a
a Navigational trigger
b Key trigger
c Transactional trigger
d None of the above
Ans : A

The system variable that records the select statement that SQL * FORMS most recently used
to populate a block is
a SYSTEM.LAST_RECORD
b SYSTEM.CURSOR_RECORD
c SYSTEM.CURSOR_FIELD
d SYSTEM.LAST_QUERY
Ans: D

Which of the following is TRUE for the ENFORCE KEY field
a ENFORCE KEY field characterstic indicates the source of the value that SQL*FORMS uses to populate the field
b A field with the ENFORCE KEY characterstic should have the INPUT ALLOWED charaterstic turned off
a Only 1 is TRUE
b Only 2 is TRUE
c Both 1 and 2 are TRUE
d Both 1 and 2 are FALSE
Ans : A

What is the maximum size of the page ?
a Characters wide & 265 characters length
b Characters wide & 265 characters length
c Characters wide & 80 characters length
d None of the above
Ans : B

A FORM is madeup of which of the following objects
a block, fields only,
b blocks, fields, pages only,
c blocks, fields, pages, triggers and form level procedures,
d Only blocks.
Ans : C

For the following statements which is true
1 Page is an object owned by a form
2 Pages are a collection of display information such as constant text and graphics.
a Only 1 is TRUE
b Only 2 is TRUE
c Both 1 & 2 are TRUE
d Both are FALSE
Ans : B

The packaged procedure that makes data in form permanent in the Database is
a Post
b Post form
c Commit form
d None of the above
Ans : C

Which of the following is TRUE for the SYSTEM VARIABLE $$date$$
a Can be assigned to a global variable
b Can be assigned to any field only during design time
c Can be assigned to any variable or field during run time
d None of the above
Ans : B

Which of the following packaged procedure is UNRESTRICTED ?
a CALL_INPUT, b CLEAR_BLOCK, c EXECUTE_QUERY, d USER_EXIT
Ans : D

Identify the RESTRICTED packaged procedure from the following
a USER_EXIT, b MESSAGE, c BREAK, d EXIT_FORM
Ans : D

What is SQL*FORMS
a SQL*FORMS is a 4GL tool for developing & executing Oracle based interactive applications.
b SQL*FORMS is a 3GL tool for connecting to the Database.
c SQL*FORMS is a reporting tool
d None of the above.
Ans : A

Name the two files that are created when you generate a form using Forms 3.0
a FMB & FMX, b FMR & FDX, c INP & FRM, d None of the above
Ans : C

What is a trigger
a A piece of logic written in PL/SQL
b Executed at the arrival of a SQL*FORMS event
c Both A & B
d None of the above
Ans : C

Which of the folowing is TRUE for a ERASE packaged procedure
1 ERASE removes an indicated Global variable & releases the memory associated with it
2 ERASE is used to remove a field from a page
1 Only 1 is TRUE
2 Only 2 is TRUE
3 Both 1 & 2 are TRUE
4 Both 1 & 2 are FALSE
Ans : 1

All datafiles related to a Tablespace are removed when the Tablespace is dropped
a TRUE
b FALSE
Ans : B

Size of Tablespace can be increased by
a Increasing the size of one of the Datafiles
b Adding one or more Datafiles
c Cannot be increased
d None of the above
Ans : B

Multiple Tablespaces can share a single datafile
a TRUE
b FALSE
Ans : B

A set of Dictionary tables are created
a Once for the Entire Database
b Every time a user is created
c Every time a Tablespace is created
d None of the above
Ans : A

Datadictionary can span across multiple Tablespaces
a TRUE
b FALSE
Ans : B

What is a DATABLOCK
a Set of Extents
b Set of Segments
c Smallest Database storage unit
d None of the above
Ans : C

Can an Integrity Constraint be enforced on a table if some existing table data does not satisfy the constraint
a Yes
b No
Ans : B

A column defined as PRIMARY KEY can have NULL's
a TRUE
b FALSE
Ans : B

A Transaction ends
a Only when it is Committed
b Only when it is Rolledback
c When it is Committed or Rolledback
d None of the above
Ans : C

A Database Procedure is stored in the Database
a In compiled form
b As source code
c Both A & B
d Not stored
Ans : C

A database trigger doesnot apply to data loaded before the definition of the trigger
a TRUE
b FALSE
Ans : A

Dedicated server configuration is
a One server process - Many user processes
b Many server processes - One user process
c One server process - One user process
d Many server processes - Many user processes
Ans : C

Which of the following does not affect the size of the SGA
a Database buffer
b Redolog buffer
c Stored procedure
d Shared pool
Ans : C

What does a COMMIT statement do to a CURSOR
a Open the Cursor
b Fetch the Cursor
c Close the Cursor
d None of the above
Ans : D

Which of the following is TRUE
1 Host variables are declared anywhere in the program
2 Host variables are declared in the DECLARE section
a Only 1 is TRUE
b Only 2 is TRUE
c Both 1 & 2are TRUE
d Both are FALSE
Ans : B

Which of the following is NOT VALID is PL/SQL
a Bool boolean;
b NUM1, NUM2 number;
c deptname dept.dname%type;
d date1 date := sysdate
Ans : B

Declare
fvar number := null; svar number := 5
Begin
goto <<>>
if fvar is null then
<<>>
svar := svar + 5
end if;
End;
What will be the value of svar after the execution ?
a Error
b 10
c 5
d None of the above
Ans : A

Which of the following is not correct about an Exception ?
a Raised automatically / Explicitly in response to an ORACLE_ERROR
b An exception will be raised when an error occurs in that block
c Process terminates after completion of error sequence.
d A Procedure or Sequence of statements may be processed.
Ans : C

Which of the following is not correct about User_Defined Exceptions ?
a Must be declared
b Must be raised explicitly
c Raised automatically in response to an Oracle error
d None of the above
Ans : C

A Stored Procedure is a
a Sequence of SQL or PL/SQL statements to perform specific function
b Stored in compiled form in the database
c Can be called from all client environmets
d All of the above
Ans : D

Which of the following statement is false
a Any procedure can raise an error and return an user message and error number
b Error number ranging from 20000 to 20999 are reserved for user defined messages
c Oracle checks Uniqueness of User defined errors
d Raise_Application_error is used for raising an user defined error.
Ans : C

Is it possible to open a cursor which is in a Package in another procedure ?
a Yes
b No
Ans : A

Is it possible to use Transactional control statements in Database Triggers?
a Yes
b No
Ans : B

Is it possible to Enable or Disable a Database trigger ?
a Yes
b No
Ans : A

PL/SQL supports datatype(s)
a Scalar datatype
b Composite datatype
c All of the above
d None of the above
Ans C

Find the ODD datatype out
a VARCHAR2
b RECORD
c BOOLEAN
d RAW
Ans : B

Which of the following is not correct about the "TABLE" datatype ?
a Can contain any no of columns
b Simulates a One-dimensional array of unlimited size
c Column datatype of any Scalar type
d None of the above
Ans : A

Find the ODD one out of the following
a OPEN
b CLOSE
c INSERT
d FETCH
Ans C

Which of the following is not correct about Cursor ?
a Cursor is a named Private SQL area
b Cursor holds temporary results
c Cursor is used for retrieving multiple rows
d SQL uses implicit Cursors to retrieve rows
Ans : B

Which of the following is NOT VALID in PL/SQL ?
a Select ... into
b Update
c Create
d Delete
Ans : C

What is the Result of the following 'VIK'NULL'RAM' ?
a Error
b VIK RAM
c VIKRAM
d NULL
Ans : C

Declare
a number := 5; b number := null; c number := 10;
Begin
if a > b AND a <> ( Select count(*) from Emp E2 where E1.SAL > E2.SAL ) will retrieve
a 3500,5000,2500
b 5000,2850
c 2850,5750
d 5000,5750
Ans : A

Is it possible to modify a Datatype of a column when column contains data ?
a Yes
b No
Ans B

Which of the following is not correct about a View ?
a To protect some of the columns of a table from other users
b Ocuupies data storage space
c To hide complexity of a query
d To hide complexity of a calculations
Ans : B

Which is not part of the Data Definiton Language ?
a CREATE
b ALTER
c ALTER SESSION
Ans : C

The Data Manipulation Language statements are
a INSERT
b UPDATE
c SELECT
d All of the above
Ans : D

EMPNO ENAME SAL
A822 RAMASWAMY 3500
A812 NARAYAN 5000
A973 UMESH
A500 BALAJI 5750
Using the above data
Select count(sal) from Emp will retrieve
a 1
b 0
c 3
d None of the above
Ans : C

If an UNIQUE KEY constraint on DATE column is created, will it accept the rows that are inserted with
SYSDATE ?
a Will
b Won't
Ans : B

What are the different events in Triggers ?
a Define, Create
b Drop, Comment
c Insert, Update, Delete
d All of the above
Ans : C

What built-in subprogram is used to manipulate images in image items ?
a Zoom_out
b Zoom_in'
c Image_zoom
d Zoom_image
Ans : C

Can we pass RECORD GROUP between FORMS ?
a Yes
b No
Ans : A

SHOW_ALERT function returns
a Boolean
b Number
c Character
d None of the above
Ans : B

What SYSTEM VARIABLE is used to refer DATABASE TIME ?
a $$dbtime$$
b $$time$$
c $$datetime$$
d None of the above
Ans : A

SYSTEM.EFFECTIVE.DATE varaible is
a Read only
b Read & Write
c Write only
d None of the above
Ans : C

How can you CALL Reports from Forms4.0 ?
a Run_Report built_in
b Call_Report built_in
c Run_Product built_in
d Call_Product built_in
Ans : C

When do you get a .PLL extension ?
a Save Library file
b Generate Library file
c Run Library file
d None of the above
Ans : A

What is built_in Subprogram ?
a Stored procedure & Function
b Collection of Subprogram
c Collection of Packages
d None of the above
Ans : D

GET_BLOCK property is a
a Restricted procedure
b Unrestricted procedure
c Library function
d None of the above
Ans : D

A CONTROL BLOCK can sometimes refer to a BASETABLE ?
a TRUE
b FALSE
Ans : B

What do you mean by CHECK BOX ?
a Two state control
b One state control
c Three state control
d none of the above
Ans : C - Please check the Correcness of this Answer ( The correct answeris 2 )

List of Values (LOV) supports
a Single column
b Multi column
c Single or Multi column
d None of the above
Ans : C

What is Library in Forms 4.0 ?
a Collection of External field
b Collection of built_in packages
c Collection of PL/SQl functions, procedures and packages
d Collection of PL/SQL procedures & triggers
Ans : C

Can we use a RESTRICTED packaged procedure in WHEN_TEXT_ITEM trigger ?
a Yes
b No
Ans : B

Can we use GO_BLOCK package in a PRE_TEXT_ITEM trigger ?
a Yes
b No
Ans : B

What type of file is used for porting Forms 4.5 applications to various platforms ?
a . FMB file
b . FMX file
c . FMT file
d . EXE file
Ans : C

What built_in procedure is used to get IMAGES in Forms 4.5 ?
a READ_IMAGE_FILE
b GET_IMAGE_FILE
c READ_FILE
d GET_FILE
Ans A

When a form is invoked with CALL_FORM does Oracle forms issues SAVEPOINT ?
a Yes
b No
Ans : A

Can we attach the same LOV to different fields in Design time ?
a Yes
b No
Ans : A

How do you pass values from one form to another form ?
a LOV
b Parameters
c Local variables
d None of the above
Ans : B

Can you copy the PROGRAM UNIT into an Object group ?
a Yes
b No
Ans : B
100. Can MULTIPLE DOCUMENT INTERFACE (MDI) be used in Forms 4.5 ?
a Yes
b No
Ans : A

Can MULTIPLE DOCUMENT INTERFACE (MDI) be used in Forms 4.5 ?
a Yes
b No
Ans : A

When is a .FMB file extension is created in Forms 4.5 ?
a Generating form
b Executing form
c Save form
d Run form
Ans : C

What is a Built_in subprogram ?
a Library
b Stored procedure & Function
c Collection of Subprograms
d None of the above
Ans : D

What is a RADIO GROUP ?
a Mutually exclusive
b Select more than one column
c Above all TRUE
d Above all FALSE
Ans : A

Identify the Odd one of the following statements ?
a Poplist
b Tlist
c List of values
d Combo box
Ans : C

What is an ALERT ?
a Modeless window
b Modal window
c Both are TRUE
d None of the above
Ans : B

Can an Alert message be changed at runtime ?
a Yes
b No
Ans : A

Can we create an LOV without an RECORD GROUP ?
a Yes
b No
Ans : B

How many no of columns can a RECORD GROUP have ?
a 10
b 20
c 50
d None of the above
Ans D

Oracle precompiler translates the EMBEDDED SQL statemens into
a Oracle FORMS
b Oracle REPORTS
c Oracle LIBRARY
d None of the above
Ans : D

Kind of COMMENT statements placed within SQL statements ?
a Asterisk(*) in column ?
b ANSI SQL style statements(...)
c C-Style comments (/*......*/)
d All the above
Ans : D

What is TERM ?
a TERM is the terminal definition file that describes the terminal from which you are using R20RUN
( Reports run time )
b TERM is the terminal definition file that describes the terminal from which you are using R20DES
( Reports designer )
c There is no Parameter called TERM in Reports 2.0
d None of the above
Ans : A

If the maximum records retrieved property of a query is set to 10, then a summary value will
be calculated
a Only for 10 records
b For all the records retrieved
c For all therecords in the referenced table
d None of the above
Ans : A

With which function of a summary item in the COMPUTE AT optio required ?
a Sum
b Standard deviation
c Variance
d % of Total function
Ans : D

For a field in a repeating frame, can the source come from a column which does not exist in
the datagroup which forms the base of the frame ?
a Yes
b No
Ans : A

What are the different file extensions that are created by Oracle Reports ?
a . RDF file & .RPX file
b . RDX file & .RDF file
c . REP file & .RDF file
d None of the above
Ans : C

Is it possible to Disable the Parameter form while running the report?
a Yes
b No
Ans : A

What are the SQL clauses supported in the link property sheet ?
a WHERE & START WITH
b WHERE & HAVING
c START WITH & HAVING
d WHERE, START WITH & HAVING
Ans : D

What are the types of Calculated columns available ?
a Summary, Place holder & Procedure column
b Summary, Procedure & Formula columns
c Procedure, Formula & Place holder columns
d Summary, Formula & Place holder columns
Ans.: D

If two groups are not linked in the data model editor, what is the hierarchy between them?
a There is no hierarchy between unlinked groups
b The group that is right ranks higher than the group that is to theleft
c The group that is above or leftmost ranks higher than the group that is to right or below it
d None of the above
Ans : C

Sequence of events takes place while starting a Database is
a Database opened, File mounted, Instance started
b Instance started, Database mounted & Database opened
c Database opened, Instance started & file mounted
d Files mounted, Instance started & Database opened
Ans : B

SYSTEM TABLESPACE can be made off-line
a Yes
b No
Ans : B

ENQUEUE_RESOURCES parameter information is derived from
a PROCESS or DDL_LOCKS & DML_LOCKS
b LOG BUFFER
c DB_BLOCK_SIZE
d DB_BLOCK_BUFFERS
Ans : A

SMON process is used to write into LOG files
a TRUE
b FALSE
Ans : B

EXP command is used
a To take Backup of the Oracle Database
b To import data from the exported dump file
c To create Rollback segments
d None of the above
Ans : A

SNAPSHOTS cannot be refreshed automatically
a TRUE
b FALSE
Ans : B

The User can set Archive file name formats
a TRUE
b FALSE
Ans : A

The following parameters are optional in init.ora parameter file DB_BLOCK_SIZE, PROCESS
a TRUE
b FALSE
Ans : B

NOARCHIEVELOG parameter is used to enable the database in Archieve mode
a TRUE
b FALSE
Ans : B

Constraints cannot be exported through Export command?
a TRUE
b FALSE
Ans : B

It is very difficult to grant and manage common priveleges needed by
different groups of database users using roles
a TRUE
b FALSE
Ans : B

The status of the Rollback segment can be viewed through
a DBA_SEGMENTS
b DBA_ROLES
c DBA_FREE_SPACES
d DBA_ROLLBACK_SEG
Ans : D

Explicitly we can assign transaction to a rollback segment
a TRUE
b FALSE
Ans : A

What file is read by ODBC to load drivers ?
a ODBC.INI
b ODBC.DLL
c ODBCDRV.INI
d None of the above
Ans : A

My Special: How the year passes away? Can u imagine a question related to this? January - Jan, February - Feb, March, April, May, June, July, August - Aug, September - Sep, October - Oct, November - Nov, December - Dec. Keep your eyes open, remember and think deeply. There are many riddles, puzzles and other questions in placement Interview related to THESE.

See More Latest Oracle Placement Question Papers for campus placements in India and walkin interviews for freshers. See 2007 and 2008 placement paper aptitude, technical, database, programming, dbms mcq / MCQs Multiple Choice Questions, reasoning questions with solutions only on previouspapers.blogspot.com

Friday, May 16, 2008

Oracle All Recent and Previous Papers

See Oracle Recent Papers :
Oracle Placement Paper 1
Oracle Placement Paper 2
Oracle Recent Placement Paper 3
Oracle Latest Sample Question Paper - 4
Oracle Latest Detailed Placement Paper 5
Oracle Placement Paper and tech round - 6
Oracle Placement Question Paper 7

Also See Oracle, SQL, etc. All Interview Questions and Answers

Keep watching for more Oracle and other IT Companies Placement Papers. See More Latest IT Companies Placement Question Papers for campus placements in India and walkin interviews for freshers. See 2007 and 2008 placement paper recent aptitude, technical, database, programming, dbms, C, testing, reasoning questions only on.

Oracle Recent Database DBMS Interview 2008 Questions - 2

Interview questions for Oracle database administrator

  1. Differentiate between TRUNCATE and DELETE

  2. What is the maximum buffer size that can be specified using the DBMS_OUTPUT.ENABLE function?

  3. Can you use a commit statement within a database trigger?

  4. What is an UTL_FILE.What are different procedures and functions associated with it?

  5. Difference between database triggers and form triggers?

  6. What is OCI. What are its uses?

  7. What are ORACLE PRECOMPILERS?

  8. What is syntax for dropping a procedure and a function? Are these operations possible?

  9. Can a function take OUT parameters. If not why?

  10. Can the default values be assigned to actual parameters?

  11. What is difference between a formal and an actual parameter?

  12. What are different modes of parameters used in functions and procedures?

  13. Difference between procedure and function.

  14. Can cursor variables be stored in PL/SQL tables.If yes how. If not why?

  15. How do you pass cursor variables in PL/SQL?

  16. How do you open and close a cursor variable.Why it is required?

  17. What should be the return type for a cursor variable.Can we use a scalar data type as return type?

  18. What is use of a cursor variable? How it is defined?

  19. What WHERE CURRENT OF clause does in a cursor?

  20. Difference between NO DATA FOUND and %NOTFOUND

  21. What is a cursor for loop?

  22. What are cursor attributes?

  23. Difference between an implicit & an explicit cursor.

  24. What is a cursor?

  25. What is the purpose of a cluster?

  26. How do you find the numbert of rows in a Table ?

  27. Display the number value in Words?

  28. What is a pseudo column. Give some examples?

  29. How you will avoid your query from using indexes?

  30. What is a OUTER JOIN?

  31. Which is more faster - IN or EXISTS?

  32. When do you use WHERE clause and when do you use HAVING clause?

  33. There is a % sign in one field of a column. What will be the query to find it?

  34. What is difference between SUBSTR and INSTR?

  35. Which datatype is used for storing graphics and images?

  36. What is difference between SQL and SQL*PLUS?

  37. What is difference between UNIQUE and PRIMARY KEY constraints?

  38. What is difference between Rename and Alias?

  39. What are various joins used while writing SUBQUERIES

See latest Oracle Interview Questions for year 2008 and previous years questions asked in hr interviews and technical, programming placement papers of leading IT MNCs. See the oracle database questions for 2007, 2008 papers and detailed interview questions with solutions. See the questions of january, february, march, april, may, june, july, august, september, october, november, december 2007 and 2008 for free online sorted by categories... Various companies papers like infosys, wipro, tcs, hcl, cisco, microsoft, ibm, sap, satyam computers, patni, mastek, ramco systems, cognizant, cap gemini, accenture, etc. are provided here.. also gaming related questions are given here in detail related to graphic design and website database real SQL questions and open source related questions.. keep watching

Oracle DBA / DBMS post Interview Questions with Detailed Solutions - 3

  1. Explain the difference between a hot backup and a cold backup and the benefits associated with each. - A hot backup is basically taking a backup of the database while it is still up and running and it must be in archive log mode. A cold backup is taking a backup of the database while it is shut down and does not require being in archive log mode. The benefit of taking a hot backup is that the database is still available for use while the backup is occurring and you can recover the database to any point in time. The benefit of taking a cold backup is that it is typically easier to administer the backup and recovery process. In addition, since you are taking cold backups the database does not require being in archive log mode and thus there will be a slight performance gain as the database is not cutting archive logs to disk.

  2. You have just had to restore from backup and do not have any control files. How would you go about bringing up this database? - I would create a text based backup control file, stipulating where on disk all the data files where and then issue the recover command with the using backup control file clause.

  3. How do you switch from an init.ora file to a spfile? - Issue the create spfile from pfile command.

  4. Explain the difference between a data block, an extent and a segment. - A data block is the smallest unit of logical storage for a database object. As objects grow they take chunks of additional storage that are composed of contiguous data blocks. These groupings of contiguous data blocks are called extents. All the extents that an object takes when grouped together are considered the segment of the database object.

  5. Give two examples of how you might determine the structure of the table DEPT. - Use the describe command or use the dbms_metadata.get_ddl package.

  6. Where would you look for errors from the database engine? - In the alert log.

  7. Compare and contrast TRUNCATE and DELETE for a table. - Both the truncate and delete command have the desired outcome of getting rid of all the rows in a table. The difference between the two is that the truncate command is a DDL operation and just moves the high water mark and produces a now rollback. The delete command, on the other hand, is a DML operation, which will produce a rollback and thus take longer to complete.

  8. Give the reasoning behind using an index. - Faster access to data blocks in a table.

  9. Give the two types of tables involved in producing a star schema and the type of data they hold. - Fact tables and dimension tables. A fact table contains measurements while dimension tables will contain data that will help describe the fact tables.

  10. What type of index should you use on a fact table? - A Bitmap index.

  11. Give two examples of referential integrity constraints. - A primary key and a foreign key.

  12. A table is classified as a parent table and you want to drop and re-create it. How would you do this without affecting the children tables? - Disable the foreign key constraint to the parent, drop the table, re-create the table, enable the foreign key constraint.

  13. Explain the difference between ARCHIVELOG mode and NOARCHIVELOG mode and the benefits and disadvantages to each. - ARCHIVELOG mode is a mode that you can put the database in for creating a backup of all transactions that have occurred in the database so that you can recover to any point in time. NOARCHIVELOG mode is basically the absence of ARCHIVELOG mode and has the disadvantage of not being able to recover to any point in time. NOARCHIVELOG mode does have the advantage of not having to write transactions to an archive log and thus increases the performance of the database slightly.

  14. What command would you use to create a backup control file? - Alter database backup control file to trace.

  15. Give the stages of instance startup to a usable state where normal users may access it. - STARTUP NOMOUNT - Instance startup. STARTUP MOUNT - The database is mounted. STARTUP OPEN - The database is opened

  16. What column differentiates the V$ views to the GV$ views and how? - The INST_ID column which indicates the instance in a RAC environment the information came from.

  17. How would you go about generating an EXPLAIN plan? - Create a plan table with utlxplan.sql. Use the explain plan set statement_id = ‘tst1′ into plan_table for a SQL statement. Look at the explain plan with utlxplp.sql or utlxpls.sql

  18. How would you go about increasing the buffer cache hit ratio? - Use the buffer cache advisory over a given workload and then query the v$db_cache_advice table. If a change was necessary then I would use the alter system set db_cache_size command.

  19. Explain an ORA-01555 - You get this error when you get a snapshot too old within rollback. It can usually be solved by increasing the undo retention or increasing the size of rollbacks. You should also look at the logic involved in the application getting the error message.

  20. Explain the difference between $ORACLE_HOME and $ORACLE_BASE. - ORACLE_BASE is the root directory for oracle. ORACLE_HOME located beneath ORACLE_BASE is where the oracle products reside

Oracle SQL Technical Interview Recent Questions - 4

Oracle interview questions

  1. What’s the command to see the current user name? Sql> show user;

  2. What’s the command to change the SQL prompt name?

    SQL> set sqlprompt “database-1 > ”
    database-1 >
    database-1 >

  3. How do I eliminate duplicate rows in an Oracle database?

    SQL> delete from table_name where rowid not in (select max(rowid) from table group by duplicate_values_field_name);

    or

    SQL> delete duplicate_values_field_name dv from table_name ta where rowid < (select min(rowid) from table_name tb where ta.dv=tb.dv);

  4. How do I display row number with records? Use the row-num pseudocolumn with query, like

    SQL> select rownum, ename from emp;

  5. How do you display the records within a given range?

    select rownum, empno, ename from emp where rowid in
    (select rowid from emp where rownum < =&rangeend
    minus
    select rowid from emp where rownum<&rangebegin);

  6. The NVL function only allows the same data type. But here’s the task: if the commission field is null, then the text “Not Applicable” should be displayed, instead of blank space. How do you write the query?

    SQL> select nvl(to_char(comm.),’Not Applicable’) from emp;

  7. Explain explicit cursor attributes. There are four cursor attributes used in Oracle: cursor_name%Found, cursor_name%NOTFOUND, cursor_name%ROWCOUNT, cursor_name%ISOPEN

  8. Explain implicit cursor attributes. Same as explicit cursor but prefixed by the word SQL: SQL%Found, SQL%NOTFOUND, SQL%ROWCOUNT, SQL%ISOPEN

  9. How do you view version information in Oracle?

    SQL> select banner from $version;

10. How do you switch to DOS prompt from SQL prompt? SQL> host

See more latest Oracle Database, DBA, gaming database - graphics, GUI recent important questions mostly asked in common interview questions pre placement and GD topics. See Technical interview java questions commonly asked placement questions for top IT MNCs in India, USA, UK, Norway, China, UAE, Denmark, Hungary, etc.

Oracle Database Latest Interview Questions - 5

Oracle interview questions

  1. What is an oracle instance?

  2. What is a view?

  3. What is referential integrity?

  4. Name the data dictionary that stores user-defined constraints?

  5. What is a collection of privileges?

  6. What is a snapshot?

  7. What is a synonym?

  8. What is a cursor?

  9. What is a sequence?

  10. What is a trigger?

  11. What is an exception?

  12. What is a partition of table?

  13. What are pseudo-columns in SQL? Provide examples.

  14. What are the Data Control statements?

  15. What is a schema?

  16. What is a type?

  17. What is a data model?

  18. What is a relation?

  19. Advantages of redo log files?

  20. What is an Archiver?

  21. What is a database buffer cache?

  22. What are the background processes in Oracle?

  23. %type and %rowtype are attributes for…?

  24. What are the steps in a two-phase commit?

  25. What is a union, intersect, minus?

  26. What is a join, explain the types of joins?

  27. What is a co-related sub-query?

  28. ODBC stands for…?

  29. Data-type used to work with integers is?

  30. Describe data models?

  31. Describe the Normalization principles?

  32. What are the types of Normalization?

  33. What is de-normalization?

Latest Oracle 2008 technical interview questions for leading IT MNCs Indian and US companies Interview Question Papers submitted by real interview candidates. Also see multiple choice questions MCQs of leading companies like Oracle, TCS, Infosys, Wipro, Satyam, Accenture, HCL, Microsoft, SAP, etc. online free here for 2008 and 2007 all months.. Good Luck for your placement papers!

Oracle PL, SQL, mysql interview questions - 6

PL - SQL Questions

  1. Which of the following statements is true about implicit cursors?

    1. Implicit cursors are used for SQL statements that are not named.

    2. Developers should use implicit cursors with great care.

    3. Implicit cursors are used in cursor for loops to handle data processing.

    4. Implicit cursors are no longer a feature in Oracle.

  2. Which of the following is not a feature of a cursor FOR loop?

    1. Record type declaration.

    2. Opening and parsing of SQL statements.

    3. Fetches records from cursor.

    4. Requires exit condition to be defined.

  3. A developer would like to use referential datatype declaration on a variable. The variable name is EMPLOYEE_LASTNAME, and the corresponding table and column is EMPLOYEE, and LNAME, respectively. How would the developer define this variable using referential datatypes?

    1. Use employee.lname%type.

    2. Use employee.lname%rowtype.

    3. Look up datatype for EMPLOYEE column on LASTNAME table and use that.

    4. Declare it to be type LONG.

  4. Which three of the following are implicit cursor attributes?

    1. %found

    2. %too_many_rows

    3. %notfound

    4. %rowcount

    5. %rowtype

  5. If left out, which of the following would cause an infinite loop to occur in a simple loop?

    1. LOOP

    2. END LOOP

    3. IF-THEN

    4. EXIT

  6. Which line in the following statement will produce an error?

    1. cursor action_cursor is

    2. select name, rate, action

    3. into action_record

    4. from action_table;

    5. There are no errors in this statement.

  7. The command used to open a CURSOR FOR loop is

    1. open

    2. fetch

    3. parse

    4. None, cursor for loops handle cursor opening implicitly.

  8. What happens when rows are found using a FETCH statement

    1. It causes the cursor to close

    2. It causes the cursor to open

    3. It loads the current row values into variables

    4. It creates the variables to hold the current row values

  9. Read the following code:

    CREATE OR REPLACE PROCEDURE find_cpt
    (v_movie_id {Argument Mode} NUMBER, v_cost_per_ticket {argument mode} NUMBER)
    IS
    BEGIN
    IF v_cost_per_ticket > 8.5 THEN
    SELECT cost_per_ticket
    INTO v_cost_per_ticket
    FROM gross_receipt
    WHERE movie_id = v_movie_id;
    END IF;
    END;

    Which mode should be used for V_COST_PER_TICKET?

    1. IN

    2. OUT

    3. RETURN

    4. IN OUT

  10. Read the following code:

    CREATE OR REPLACE TRIGGER update_show_gross
    {trigger information}
    BEGIN
    {additional code}
    END;

    The trigger code should only execute when the column, COST_PER_TICKET, is greater than $3. Which trigger information will you add?

    1. WHEN (new.cost_per_ticket > 3.75)

    2. WHEN (:new.cost_per_ticket > 3.75

    3. WHERE (new.cost_per_ticket > 3.75)

    4. WHERE (:new.cost_per_ticket > 3.75)

  11. What is the maximum number of handlers processed before the PL/SQL block is exited when an exception occurs?

    1. Only one

    2. All that apply

    3. All referenced

    4. None

  12. For which trigger timing can you reference the NEW and OLD qualifiers?

    1. Statement and Row

    2. Statement only

    3. Row only

    4. Oracle Forms trigger

  13. Read the following code:

    CREATE OR REPLACE FUNCTION get_budget(v_studio_id IN NUMBER)
    RETURN number IS

    v_yearly_budget NUMBER;

    BEGIN
    SELECT yearly_budget
    INTO v_yearly_budget
    FROM studio
    WHERE id = v_studio_id;

    RETURN v_yearly_budget;
    END;

    Which set of statements will successfully invoke this function within SQL*Plus?

    1. VARIABLE g_yearly_budget NUMBER
      EXECUTE g_yearly_budget := GET_BUDGET(11);

    2. VARIABLE g_yearly_budget NUMBER
      EXECUTE :g_yearly_budget := GET_BUDGET(11);

    3. VARIABLE :g_yearly_budget NUMBER
      EXECUTE :g_yearly_budget := GET_BUDGET(11);

    4. VARIABLE g_yearly_budget NUMBER
      :g_yearly_budget := GET_BUDGET(11);

  14. CREATE OR REPLACE PROCEDURE update_theater
    (v_name IN VARCHAR v_theater_id IN NUMBER) IS
    BEGIN
    UPDATE theater
    SET name = v_name
    WHERE id = v_theater_id;
    END update_theater;

    When invoking this procedure, you encounter the error:

    ORA-000: Unique constraint(SCOTT.THEATER_NAME_UK) violated.

    How should you modify the function to handle this error?

    1. An user defined exception must be declared and associated with the error code and handled in the EXCEPTION section.

    2. Handle the error in EXCEPTION section by referencing the error code directly.

    3. Handle the error in the EXCEPTION section by referencing the UNIQUE_ERROR predefined exception.

    4. Check for success by checking the value of SQL%FOUND immediately after the UPDATE statement.

  15. Read the following code:

    CREATE OR REPLACE PROCEDURE calculate_budget IS
    v_budget studio.yearly_budget%TYPE;
    BEGIN
    v_budget := get_budget(11);
    IF v_budget <>

    You are about to add an argument to CALCULATE_BUDGET. What effect will this have?

    1. The GET_BUDGET function will be marked invalid and must be recompiled before the next execution.

    2. The SET_BUDGET function will be marked invalid and must be recompiled before the next execution.

    3. Only the CALCULATE_BUDGET procedure needs to be recompiled.

    4. All three procedures are marked invalid and must be recompiled.

  16. Which procedure can be used to create a customized error message?

    1. RAISE_ERROR

    2. SQLERRM

    3. RAISE_APPLICATION_ERROR

    4. RAISE_SERVER_ERROR

  17. The CHECK_THEATER trigger of the THEATER table has been disabled. Which command can you issue to enable this trigger?

    1. ALTER TRIGGER check_theater ENABLE;

    2. ENABLE TRIGGER check_theater;

    3. ALTER TABLE check_theater ENABLE check_theater;

    4. ENABLE check_theater;

  18. Examine this database trigger

    CREATE OR REPLACE TRIGGER prevent_gross_modification
    {additional trigger information}
    BEGIN
    IF TO_CHAR(sysdate, DY) = MON
    THEN
    RAISE_APPLICATION_ERROR(-20000,Gross receipts cannot be deleted on
     Monday);
    END IF;
    END;

    This trigger must fire before each DELETE of the GROSS_RECEIPT table. It should fire only once for the entire DELETE statement. What additional information must you add?

    1. BEFORE DELETE ON gross_receipt

    2. AFTER DELETE ON gross_receipt

    3. BEFORE (gross_receipt DELETE)

    4. FOR EACH ROW DELETED FROM gross_receipt

  19. Examine this function:

    CREATE OR REPLACE FUNCTION set_budget
    (v_studio_id IN NUMBER, v_new_budget IN NUMBER) IS
    BEGIN
    UPDATE studio
    SET yearly_budget = v_new_budget
    WHERE id = v_studio_id;

    IF SQL%FOUND THEN
    RETURN TRUEl;
    ELSE
    RETURN FALSE;
    END IF;

    COMMIT;
    END;

    Which code must be added to successfully compile this function?

    1. Add RETURN right before the IS keyword.

    2. Add RETURN number right before the IS keyword.

    3. Add RETURN boolean right after the IS keyword.

    4. Add RETURN boolean right before the IS keyword.

  20. Under which circumstance must you recompile the package body after recompiling the package specification?

    1. Altering the argument list of one of the package constructs

    2. Any change made to one of the package constructs

    3. Any SQL statement change made to one of the package constructs

    4. Removing a local variable from the DECLARE section of one of the package constructs

  21. Procedure and Functions are explicitly executed. This is different from a database trigger. When is a database trigger executed?

    1. When the transaction is committed

    2. During the data manipulation statement

    3. When an Oracle supplied package references the trigger

    4. During a data manipulation statement and when the transaction is committed

  22. Which Oracle supplied package can you use to output values and messages from database triggers, stored procedures and functions within SQL*Plus?

    1. DBMS_DISPLAY

    2. DBMS_OUTPUT

    3. DBMS_LIST

    4. DBMS_DESCRIBE

  23. What occurs if a procedure or function terminates with failure without being handled?

    1. Any DML statements issued by the construct are still pending and can be committed or rolled back.

    2. Any DML statements issued by the construct are committed

    3. Unless a GOTO statement is used to continue processing within the BEGIN section, the construct terminates.

    4. The construct rolls back any DML statements issued and returns the unhandled exception to the calling environment.

  24. Examine this code

    BEGIN
    theater_pck.v_total_seats_sold_overall := theater_pck.get_total_for_year;
    END;

    For this code to be successful, what must be true?

    1. Both the V_TOTAL_SEATS_SOLD_OVERALL variable and the GET_TOTAL_FOR_YEAR function must exist only in the body of the THEATER_PCK package.

    2. Only the GET_TOTAL_FOR_YEAR variable must exist in the specification of the THEATER_PCK package.

    3. Only the V_TOTAL_SEATS_SOLD_OVERALL variable must exist in the specification of the THEATER_PCK package.

    4. Both the V_TOTAL_SEATS_SOLD_OVERALL variable and the GET_TOTAL_FOR_YEAR function must exist in the specification of the THEATER_PCK package.

  25. A stored function must return a value based on conditions that are determined at runtime. Therefore, the SELECT statement cannot be hard-coded and must be created dynamically when the function is executed. Which Oracle supplied package will enable this feature?

    1. DBMS_DDL

    2. DBMS_DML

    3. DBMS_SYN

    4. DBMS_SQL

Oracle and Java Latest / Recent Placement Paper questions and answers for programming / technical paper for leading IT Companies Infosys, Wipro, IBM, CISCO, Oracle, SAP, TCS, Satyam Computers, HCL, Microsoft, Ramco, Cognizant, Verizon, Cingular, IFlex Solutions Landran Chandigarh, Mohali, Delhi, bangalore, chennai, hyderabad, pune, kolkata, latest interview question papers with complete solutions submitted by real candidates and answered by experts. Keep watching out for 2007, 2008 and recent papers for all months - january, februrary, march, april, may, june, july, august, september, october, november, december. Good luck for your papers!!